Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Q
qtquickcontrols-nemo
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
NemoMobile
qtquickcontrols-nemo
Commits
48101f4f
Commit
48101f4f
authored
Mar 26, 2014
by
Aleksi Suomalainen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[dialog] Query Dialog 0.1
parent
c6116845
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
112 additions
and
2 deletions
+112
-2
QueryDialogPage.qml
examples/touch/content/QueryDialogPage.qml
+57
-0
main.qml
examples/touch/main.qml
+4
-0
resources.qrc
examples/touch/resources.qrc
+1
-0
touch.pro
examples/touch/touch.pro
+2
-1
QueryDialog.qml
src/controls/QueryDialog.qml
+45
-0
controls.pro
src/controls/controls.pro
+2
-1
qmldir
src/controls/qmldir
+1
-0
No files found.
examples/touch/content/QueryDialogPage.qml
0 → 100644
View file @
48101f4f
/****************************************************************************************
**
** Copyright (C) 2014 Aleksi Suomalainen <suomalainen.aleksi@gmail.com>
** All rights reserved.
**
** You may use this file under the terms of BSD license as follows:
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the author nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR
** ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
****************************************************************************************/
import
QtQuick
2.1
import
QtQuick
.
Controls
1.0
//needed for the Stack attached property
import
QtQuick
.
Controls
.
Nemo
1.0
import
QtQuick
.
Controls
.
Styles
.
Nemo
1.0
Page
{
id
:
root
tools
:
ToolBarLayoutExample
{
title
:
"
Query dialog example
"
}
QueryDialog
{
cancelText
:
"
Cancel
"
acceptText
:
"
Delete
"
headingText
:
"
Are you sure you want to delete this?
"
onAccepted
:
{
result
.
text
=
"
User accepted
"
}
onCanceled
:
{
result
.
text
=
"
User canceled
"
}
}
Label
{
id
:
result
anchors.centerIn
:
parent
}
}
examples/touch/main.qml
View file @
48101f4f
...
@@ -103,6 +103,10 @@ ApplicationWindow {
...
@@ -103,6 +103,10 @@ ApplicationWindow {
title
:
"
ButtonRow
"
title
:
"
ButtonRow
"
page
:
"
content/ButtonRowPage.qml
"
page
:
"
content/ButtonRowPage.qml
"
}
}
ListElement
{
title
:
"
Query Dialog
"
page
:
"
content/QueryDialogPage.qml
"
}
}
}
...
...
examples/touch/resources.qrc
View file @
48101f4f
...
@@ -21,5 +21,6 @@
...
@@ -21,5 +21,6 @@
<file>content/LabelPage.qml</file>
<file>content/LabelPage.qml</file>
<file>content/CheckboxPage.qml</file>
<file>content/CheckboxPage.qml</file>
<file>content/ButtonRowPage.qml</file>
<file>content/ButtonRowPage.qml</file>
<file>content/QueryDialogPage.qml</file>
</qresource>
</qresource>
</RCC>
</RCC>
examples/touch/touch.pro
View file @
48101f4f
...
@@ -22,7 +22,8 @@ OTHER_FILES += \
...
@@ -22,7 +22,8 @@ OTHER_FILES += \
content
/
SpinnerPage
.
qml
\
content
/
SpinnerPage
.
qml
\
content
/
LabelPage
.
qml
\
content
/
LabelPage
.
qml
\
content
/
CheckboxPage
.
qml
\
content
/
CheckboxPage
.
qml
\
content
/
ButtonRowPage
.
qml
content
/
ButtonRowPage
.
qml
\
content
/
QueryDialogPage
.
qml
RESOURCES
+=
\
RESOURCES
+=
\
resources
.
qrc
resources
.
qrc
...
...
src/controls/QueryDialog.qml
0 → 100644
View file @
48101f4f
import
QtQuick
2.0
Rectangle
{
id
:
shell
anchors.fill
:
parent
opacity
:
0.7
color
:
"
black
"
signal
accepted
()
signal
canceled
()
property
alias
cancelText
:
cancel
.
text
property
alias
acceptText
:
accept
.
text
property
alias
headingText
:
heading
.
text
Label
{
width
:
parent
.
width
*
0.8
id
:
heading
anchors.centerIn
:
parent
wrapMode
:
Text
.
Wrap
}
Button
{
id
:
cancel
width
:
parent
.
width
/
2
anchors
{
left
:
parent
.
left
bottom
:
parent
.
bottom
}
onClicked
:
{
shell
.
canceled
()
shell
.
destroy
()
}
}
Button
{
id
:
accept
width
:
parent
.
width
/
2
anchors
{
left
:
cancel
.
right
bottom
:
parent
.
bottom
}
onClicked
:
{
shell
.
accepted
()
shell
.
destroy
()
}
}
}
src/controls/controls.pro
View file @
48101f4f
...
@@ -18,7 +18,8 @@ QML_FILES += \
...
@@ -18,7 +18,8 @@ QML_FILES += \
OTHER_FILES
+=
qmldir
\
OTHER_FILES
+=
qmldir
\
$$
QML_FILES
\
$$
QML_FILES
\
ButtonRow
.
qml
ButtonRow
.
qml
\
QueryDialog
.
qml
HEADERS
+=
\
HEADERS
+=
\
qquicknemocontrolsextensionplugin
.
h
\
qquicknemocontrolsextensionplugin
.
h
\
...
...
src/controls/qmldir
View file @
48101f4f
...
@@ -15,6 +15,7 @@ Spinner 1.0 Spinner.qml
...
@@ -15,6 +15,7 @@ Spinner 1.0 Spinner.qml
Label 1.0 Label.qml
Label 1.0 Label.qml
CheckBox 1.0 Checkbox.qml
CheckBox 1.0 Checkbox.qml
ButtonRow 1.0 ButtonRow.qml
ButtonRow 1.0 ButtonRow.qml
QueryDialog 1.0 QueryDialog.qml
# MIRRORED CONTROLS:
# MIRRORED CONTROLS:
# These are the controls that we take directly from official QQC.
# These are the controls that we take directly from official QQC.
# This is to avoid having to "import QtQuick.Controls" when using controls
# This is to avoid having to "import QtQuick.Controls" when using controls
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment