Style and naming correction
Signed-off-by: Juraj Oravec <jurajoravec@mailo.com>
This commit is contained in:
parent
04e40f1241
commit
7ee07ad363
@ -37,4 +37,3 @@ different from yours.
|
||||
### Code
|
||||
The code for this example can be found at
|
||||
[extensions/qml_tutorial_5](../extensions/qml_tutorial_5)
|
||||
|
||||
|
@ -17,4 +17,3 @@ to copy something and other to copy image URL to the clipboard.
|
||||
### Code
|
||||
The code for this example can be found at
|
||||
[extensions/qml_tutorial_6](../extensions/qml_tutorial_6)
|
||||
|
||||
|
@ -4,13 +4,13 @@ import QtQuick 2.3
|
||||
Falkon.PluginInterface {
|
||||
|
||||
QtObject {
|
||||
id: tutorial3Object
|
||||
id: tutorial4Object
|
||||
property int clickCount
|
||||
}
|
||||
|
||||
init: function(state, settingsPath) {
|
||||
console.log(i18n('"Tutorial4" plugin loaded'))
|
||||
tutorial3Object.clickCount = 0;
|
||||
tutorial4Object.clickCount = 0;
|
||||
}
|
||||
|
||||
testPlugin: function() {
|
||||
@ -22,8 +22,8 @@ Falkon.PluginInterface {
|
||||
}
|
||||
|
||||
function buttonClicked() {
|
||||
tutorial3Object.clickCount++;
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial3Object.clickCount))
|
||||
tutorial4Object.clickCount++;
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial4Object.clickCount))
|
||||
}
|
||||
|
||||
Falkon.BrowserAction {
|
||||
@ -32,7 +32,7 @@ Falkon.PluginInterface {
|
||||
title: i18n('Qml Tutorial 4')
|
||||
toolTip: i18n('My little button')
|
||||
icon: 'falkon'
|
||||
badgeText: tutorial3Object.clickCount
|
||||
badgeText: tutorial4Object.clickCount
|
||||
location: Falkon.BrowserAction.NavigationToolBar | Falkon.BrowserAction.StatusBar
|
||||
popup: Rectangle {
|
||||
width: 100;
|
||||
@ -48,8 +48,8 @@ Falkon.PluginInterface {
|
||||
})
|
||||
|
||||
action_always.triggered.connect(function() {
|
||||
tutorial3Object.clickCount++;
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial3Object.clickCount))
|
||||
tutorial4Object.clickCount++;
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial4Object.clickCount))
|
||||
})
|
||||
|
||||
if (webHitTestResult.isImage()) {
|
||||
@ -59,9 +59,9 @@ Falkon.PluginInterface {
|
||||
})
|
||||
|
||||
action_image.triggered.connect(function() {
|
||||
tutorial3Object.clickCount += 2;
|
||||
tutorial4Object.clickCount += 2;
|
||||
console.log(i18n('"Tutorial4" Surprise, this is an image with url: ' + webHitTestResult.imageUrl))
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial3Object.clickCount))
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial4Object.clickCount))
|
||||
})
|
||||
}
|
||||
|
||||
@ -81,8 +81,8 @@ Falkon.PluginInterface {
|
||||
})
|
||||
|
||||
sm_action_always.triggered.connect(function() {
|
||||
tutorial3Object.clickCount++;
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial3Object.clickCount))
|
||||
tutorial4Object.clickCount++;
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial4Object.clickCount))
|
||||
})
|
||||
|
||||
if (webHitTestResult.isImage()) {
|
||||
@ -92,9 +92,9 @@ Falkon.PluginInterface {
|
||||
})
|
||||
|
||||
sm_action_image.triggered.connect(function() {
|
||||
tutorial3Object.clickCount += 2;
|
||||
tutorial4Object.clickCount += 2;
|
||||
console.log(i18n('"Tutorial4" Surprise, this is an image with url: ' + webHitTestResult.imageUrl))
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial3Object.clickCount))
|
||||
console.log(i18n('"Tutorial4" clickCount increased to ' + tutorial4Object.clickCount))
|
||||
})
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user