Merge lp:~abreu-alexandre/unity-webapps-qml/backportoxide-1404 into lp:unity-webapps-qml/14.04

Proposed by Alexandre Abreu
Status: Merged
Approved by: Alexandre Abreu
Approved revision: 114
Merged at revision: 114
Proposed branch: lp:~abreu-alexandre/unity-webapps-qml/backportoxide-1404
Merge into: lp:unity-webapps-qml/14.04
Diff against target: 101 lines (+17/-9)
5 files modified
debian/control (+1/-3)
src/Ubuntu/UnityWebApps/UnityWebApps.js (+1/-2)
src/Ubuntu/UnityWebApps/UnityWebApps.qml (+9/-0)
src/Ubuntu/UnityWebApps/UnityWebAppsUtils.js (+5/-3)
src/Ubuntu/UnityWebApps/common/js/unity-backend-messaging-proxy.js (+1/-1)
To merge this branch: bzr merge lp:~abreu-alexandre/unity-webapps-qml/backportoxide-1404
Reviewer Review Type Date Requested Status
WebApps Pending
Review via email: mp+243288@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/control'
--- debian/control 2014-04-30 01:13:30 +0000
+++ debian/control 2014-12-01 14:06:58 +0000
@@ -8,7 +8,6 @@
8 libnotify-dev,8 libnotify-dev,
9# depend on oxide so that we don't build for archs that we can't install on9# depend on oxide so that we don't build for archs that we can't install on
10 liboxideqtcore0,10 liboxideqtcore0,
11 libqt5webkit5-dev,
12 libunity-action-qt1-dev,11 libunity-action-qt1-dev,
13 libunity-dev,12 libunity-dev,
14 pkg-config,13 pkg-config,
@@ -28,8 +27,7 @@
2827
29Package: unity-webapps-qml28Package: unity-webapps-qml
30Architecture: any29Architecture: any
31Depends: libqt5webkit5-qmlwebkitplugin,30Depends: liboxideqt-qmlplugin (>= 1.3.4),
32 liboxideqt-qmlplugin (>= 1.0),
33 qtdeclarative5-qtquick2-plugin,31 qtdeclarative5-qtquick2-plugin,
34 qtdeclarative5-unity-action-plugin,32 qtdeclarative5-unity-action-plugin,
35 qtdeclarative5-ubuntu-ui-toolkit-plugin | qtdeclarative5-ubuntu-ui-toolkit-plugin-gles,33 qtdeclarative5-ubuntu-ui-toolkit-plugin | qtdeclarative5-ubuntu-ui-toolkit-plugin-gles,
3634
=== modified file 'src/Ubuntu/UnityWebApps/UnityWebApps.js'
--- src/Ubuntu/UnityWebApps/UnityWebApps.js 2014-03-18 18:52:11 +0000
+++ src/Ubuntu/UnityWebApps/UnityWebApps.js 2014-12-01 14:06:58 +0000
@@ -66,8 +66,7 @@
66 var cb = this._onMessageReceivedCallback.bind(self);66 var cb = this._onMessageReceivedCallback.bind(self);
67 self._bindeeProxies.messageReceivedConnect(cb);67 self._bindeeProxies.messageReceivedConnect(cb);
6868
69 cb = this._onLoadingStartedCallback.bind(self);69 this._onLoadingStartedCallback();
70 self._bindeeProxies.loadingStartedConnect(cb);
71 },70 },
7271
73 /**72 /**
7473
=== modified file 'src/Ubuntu/UnityWebApps/UnityWebApps.qml'
--- src/Ubuntu/UnityWebApps/UnityWebApps.qml 2014-03-26 15:52:46 +0000
+++ src/Ubuntu/UnityWebApps/UnityWebApps.qml 2014-12-01 14:06:58 +0000
@@ -134,6 +134,13 @@
134 */134 */
135 property var actionsContext: null135 property var actionsContext: null
136136
137 /*!
138 \qmlsignal UnityWebApps::userScriptsInjected()
139
140 This signal is emitted when the component has completed its initialization and
141 the userscripts have been injected into the binded webview.
142 */
143 signal userScriptsInjected()
137144
138 /*!145 /*!
139 \qmlproperty string UnityWebApps::_opt_backendProxies146 \qmlproperty string UnityWebApps::_opt_backendProxies
@@ -210,6 +217,8 @@
210217
211 internal.backends = backends;218 internal.backends = backends;
212 internal.instance = instance;219 internal.instance = instance;
220
221 userScriptsInjected();
213 }222 }
214223
215 /*!224 /*!
216225
=== modified file 'src/Ubuntu/UnityWebApps/UnityWebAppsUtils.js'
--- src/Ubuntu/UnityWebApps/UnityWebAppsUtils.js 2014-04-02 18:16:34 +0000
+++ src/Ubuntu/UnityWebApps/UnityWebAppsUtils.js 2014-12-01 14:06:58 +0000
@@ -62,7 +62,7 @@
62 this.webview = webview;62 this.webview = webview;
63 this.disposer = disposer;63 this.disposer = disposer;
64 this.makeSignalDisconnecter = makeSignalDisconnecter;64 this.makeSignalDisconnecter = makeSignalDisconnecter;
65 this._WEBAPPS_USER_SCRIPT_CONTEXT = "oxide://UnityWebappsApi";65 this._WEBAPPS_USER_SCRIPT_CONTEXT = "oxide://main-world";
66}66}
67OxideWebviewAdapter.prototype = {67OxideWebviewAdapter.prototype = {
68 injectUserScripts: function(userScriptUrls) {68 injectUserScripts: function(userScriptUrls) {
@@ -72,8 +72,10 @@
72 var scriptStart = "import com.canonical.Oxide 1.0 as Oxide; Oxide.UserScript { context:";72 var scriptStart = "import com.canonical.Oxide 1.0 as Oxide; Oxide.UserScript { context:";
73 var scriptEnd = "}";73 var scriptEnd = "}";
74 var statement = scriptStart +74 var statement = scriptStart +
75 '"' + this._WEBAPPS_USER_SCRIPT_CONTEXT + '"' +75 '"' + this._WEBAPPS_USER_SCRIPT_CONTEXT
76 '; matchAllFrames: false; url: "' + userScriptUrls[i] + '";' + scriptEnd;76 + '"'
77 + '; matchAllFrames: false; emulateGreasemonkey: true; url: "'
78 + userScriptUrls[i] + '";' + scriptEnd;
77 context.addUserScript(Qt.createQmlObject(statement, this.webview));79 context.addUserScript(Qt.createQmlObject(statement, this.webview));
78 }80 }
79 },81 },
8082
=== modified file 'src/Ubuntu/UnityWebApps/common/js/unity-backend-messaging-proxy.js'
--- src/Ubuntu/UnityWebApps/common/js/unity-backend-messaging-proxy.js 2014-03-28 13:21:47 +0000
+++ src/Ubuntu/UnityWebApps/common/js/unity-backend-messaging-proxy.js 2014-12-01 14:06:58 +0000
@@ -4,7 +4,7 @@
4 navigator.qt.postMessage) {4 navigator.qt.postMessage) {
5 return new UnityQtWebkitBackendMessagingProxy();5 return new UnityQtWebkitBackendMessagingProxy();
6 }6 }
7 else if (window.oxide) {7 else if (oxide) {
8 return new UnityOxideBackendMessagingProxy();8 return new UnityOxideBackendMessagingProxy();
9 }9 }
10 return null;10 return null;

Subscribers

People subscribed via source and target branches

to all changes: