Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
J
jami-client-windows
Manage
Activity
Members
Plan
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
savoirfairelinux
jami-client-windows
Commits
7e05570f
Commit
7e05570f
authored
Dec 27, 2018
by
Andreas Traczyk
Browse files
Options
Downloads
Patches
Plain Diff
message view: fix image loading by disabling web security
Change-Id: Ic385202733a310e4b8d85bca0fe9d53d107b71c1
parent
3199a1f0
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
main.cpp
+10
-1
10 additions, 1 deletion
main.cpp
messagewebview.cpp
+6
-0
6 additions, 0 deletions
messagewebview.cpp
with
16 additions
and
1 deletion
main.cpp
+
10
−
1
View file @
7e05570f
...
@@ -106,7 +106,16 @@ main(int argc, char *argv[])
...
@@ -106,7 +106,16 @@ main(int argc, char *argv[])
QGuiApplication
::
setAttribute
(
Qt
::
AA_EnableHighDpiScaling
);
QGuiApplication
::
setAttribute
(
Qt
::
AA_EnableHighDpiScaling
);
QGuiApplication
::
setAttribute
(
Qt
::
AA_UseHighDpiPixmaps
);
QGuiApplication
::
setAttribute
(
Qt
::
AA_UseHighDpiPixmaps
);
QApplication
a
(
argc
,
argv
);
char
ARG_DISABLE_WEB_SECURITY
[]
=
"--disable-web-security"
;
int
newArgc
=
argc
+
1
+
1
;
char
**
newArgv
=
new
char
*
[
newArgc
];
for
(
int
i
=
0
;
i
<
argc
;
i
++
)
{
newArgv
[
i
]
=
argv
[
i
];
}
newArgv
[
argc
]
=
ARG_DISABLE_WEB_SECURITY
;
newArgv
[
argc
+
1
]
=
nullptr
;
QApplication
a
(
newArgc
,
newArgv
);
QCoreApplication
::
setOrganizationDomain
(
"jami.net"
);
QCoreApplication
::
setOrganizationDomain
(
"jami.net"
);
QCoreApplication
::
setApplicationName
(
"Ring"
);
QCoreApplication
::
setApplicationName
(
"Ring"
);
...
...
This diff is collapsed.
Click to expand it.
messagewebview.cpp
+
6
−
0
View file @
7e05570f
...
@@ -56,6 +56,12 @@ MessageWebView::MessageWebView(QWidget *parent)
...
@@ -56,6 +56,12 @@ MessageWebView::MessageWebView(QWidget *parent)
settings
()
->
setAttribute
(
QWebEngineSettings
::
ScreenCaptureEnabled
,
false
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
ScreenCaptureEnabled
,
false
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
LinksIncludedInFocusChain
,
false
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
LinksIncludedInFocusChain
,
false
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
LocalStorageEnabled
,
false
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
LocalStorageEnabled
,
false
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
AllowRunningInsecureContent
,
true
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
LocalContentCanAccessRemoteUrls
,
true
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
XSSAuditingEnabled
,
false
);
settings
()
->
setAttribute
(
QWebEngineSettings
::
LocalContentCanAccessFileUrls
,
true
);
settings
()
->
setFontSize
(
QWebEngineSettings
::
MinimumFontSize
,
2
);
setContextMenuPolicy
(
Qt
::
ContextMenuPolicy
::
NoContextMenu
);
setContextMenuPolicy
(
Qt
::
ContextMenuPolicy
::
NoContextMenu
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment