From 76dd5b4749516882b7fb44c40864450cff91441a Mon Sep 17 00:00:00 2001 From: Shawn Rutledge Date: Tue, 3 Oct 2017 08:07:30 +0200 Subject: pointerhandlers manual test: get command-line arg working again 4e7041c65216ada4f5fb604a9df840152ba60317 added a convenient feature to launch a specific test rather than needing to use the menu; e8f36458276cc989dc5f0c33ec27c90fad15137b broke it; and at some point the functions removed there were added back in a way that couldn't work (during a merge?) addExample is in use everywhere; showExample is in use only for the pointer handlers manual test; and hideExample isn't in use, so we can remove it again. Change-Id: I19cacbd3324889da9768b73ec2640aa0c1de96ef Reviewed-by: Shawn Rutledge --- examples/quick/shared/LauncherList.qml | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) (limited to 'examples/quick/shared/LauncherList.qml') diff --git a/examples/quick/shared/LauncherList.qml b/examples/quick/shared/LauncherList.qml index 2d1d29c585..40b7684712 100644 --- a/examples/quick/shared/LauncherList.qml +++ b/examples/quick/shared/LauncherList.qml @@ -47,18 +47,11 @@ Rectangle { //function used to add to model A) to enforce scheme B) to allow Qt.resolveUrl in url assignments color: "#eee" - function addExample(name, desc, url) - { + function addExample(name, desc, url) { myModel.append({"name":name, "description":desc, "url":url}) } - - function hideExample() - { - ei.visible = false; - } - function showExample(url) - { - ei.exampleUrl = url; + function showExample(url) { + pageComponent.createObject(pageContainer, { exampleUrl: url }).show() } // The container rectangle here is used to give a nice "feel" when @@ -71,10 +64,7 @@ Rectangle { id: launcherList clip: true delegate: SimpleLauncherDelegate{ - onClicked: { - var page = pageComponent.createObject(pageContainer, { exampleUrl: url }) - page.show() - } + onClicked: showExample(url) } model: ListModel {id:myModel} anchors.fill: parent -- cgit v1.2.3 From ea6cd0de3cbde7ae51bb6f9e2b01dd2785af85a0 Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Thu, 28 Sep 2017 15:54:49 +0200 Subject: Fix outdated BSD license header Change-Id: Icc08925454445fc9497fb3bfd2c26efe90605983 Reviewed-by: Jani Heikkinen --- examples/quick/shared/LauncherList.qml | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'examples/quick/shared/LauncherList.qml') diff --git a/examples/quick/shared/LauncherList.qml b/examples/quick/shared/LauncherList.qml index ba9ee6c5d2..65dec0f29f 100644 --- a/examples/quick/shared/LauncherList.qml +++ b/examples/quick/shared/LauncherList.qml @@ -1,13 +1,23 @@ /**************************************************************************** ** ** Copyright (C) 2017 Crimson AS -** Copyright (C) 2015 The Qt Company Ltd. -** Contact: http://www.qt.io/licensing/ +** Copyright (C) 2017 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ ** ** This file is part of the examples of the Qt Toolkit. ** ** $QT_BEGIN_LICENSE:BSD$ -** You may use this file under the terms of the BSD license as follows: +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** BSD License Usage +** Alternatively, you may use this file under the terms of the BSD license +** as follows: ** ** "Redistribution and use in source and binary forms, with or without ** modification, are permitted provided that the following conditions are -- cgit v1.2.3