Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linphone-desktop
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
Administrator
linphone-desktop
Commits
a3e49588
Commit
a3e49588
authored
Mar 31, 2017
by
Ronan Abhamon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(ui/modules/Common/Form/DroppableTextArea): add a shortcut to insert new lines
parent
70b4e4cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
1 deletion
+14
-1
DroppableTextArea.qml
...hone-desktop/ui/modules/Common/Form/DroppableTextArea.qml
+14
-1
No files found.
linphone-desktop/ui/modules/Common/Form/DroppableTextArea.qml
View file @
a3e49588
...
...
@@ -54,6 +54,12 @@ Item {
TextArea.flickable
:
TextArea
{
id
:
textArea
function
handleValidation
()
{
if
(
text
.
length
!==
0
)
{
validText
(
text
)
}
}
background
:
Rectangle
{
color
:
DroppableTextAreaStyle
.
backgroundColor
}
...
...
@@ -65,7 +71,14 @@ Item {
wrapMode
:
TextArea
.
Wrap
Component.onCompleted
:
forceActiveFocus
()
Keys.onReturnPressed
:
text
.
length
!==
0
&&
validText
(
text
)
Keys.onPressed
:
{
if
(
event
.
matches
(
StandardKey
.
InsertLineSeparator
))
{
insert
(
cursorPosition
,
''
)
}
else
if
(
event
.
key
===
Qt
.
Key_Return
||
event
.
key
===
Qt
.
Key_Enter
)
{
handleValidation
()
}
}
}
}
...
...
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