Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
J
jami-client-windows
Manage
Activity
Members
Plan
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
savoirfairelinux
jami-client-windows
Commits
d1c35b4d
Commit
d1c35b4d
authored
9 years ago
by
Edric
Committed by
gerrit2
9 years ago
Browse files
Options
Downloads
Patches
Plain Diff
make add to contact moveable
Change-Id: Icfc75740ec633137a22abb35ad477a8e98ec07c2 Tuleap: #713
parent
f05ef071
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
contactpicker.cpp
+19
-1
19 additions, 1 deletion
contactpicker.cpp
contactpicker.h
+4
-0
4 additions, 0 deletions
contactpicker.h
with
23 additions
and
1 deletion
contactpicker.cpp
+
19
−
1
View file @
d1c35b4d
...
@@ -19,7 +19,7 @@
...
@@ -19,7 +19,7 @@
#include
"contactpicker.h"
#include
"contactpicker.h"
#include
"ui_contactpicker.h"
#include
"ui_contactpicker.h"
#include
<QMouseEvent>
#include
"categorizedcontactmodel.h"
#include
"categorizedcontactmodel.h"
#include
"personmodel.h"
#include
"personmodel.h"
...
@@ -107,3 +107,21 @@ ContactPicker::on_searchBar_textChanged(const QString &arg1)
...
@@ -107,3 +107,21 @@ ContactPicker::on_searchBar_textChanged(const QString &arg1)
{
{
contactProxyModel_
->
setFilterRegExp
(
QRegExp
(
arg1
,
Qt
::
CaseInsensitive
,
QRegExp
::
FixedString
));
contactProxyModel_
->
setFilterRegExp
(
QRegExp
(
arg1
,
Qt
::
CaseInsensitive
,
QRegExp
::
FixedString
));
}
}
void
ContactPicker
::
mousePressEvent
(
QMouseEvent
*
event
)
{
mpos_
=
event
->
pos
();
if
(
not
rect
().
contains
(
mpos_
))
QDialog
::
reject
();
}
void
ContactPicker
::
mouseMoveEvent
(
QMouseEvent
*
event
)
{
if
(
event
->
buttons
()
&
Qt
::
LeftButton
)
{
QPoint
diff
=
event
->
pos
()
-
mpos_
;
QPoint
newpos
=
this
->
pos
()
+
diff
;
this
->
move
(
newpos
);
}
}
This diff is collapsed.
Click to expand it.
contactpicker.h
+
4
−
0
View file @
d1c35b4d
...
@@ -50,6 +50,9 @@ public:
...
@@ -50,6 +50,9 @@ public:
explicit
ContactPicker
(
ContactMethod
*
number
,
QWidget
*
parent
=
0
);
explicit
ContactPicker
(
ContactMethod
*
number
,
QWidget
*
parent
=
0
);
~
ContactPicker
();
~
ContactPicker
();
protected:
void
mousePressEvent
(
QMouseEvent
*
event
);
void
mouseMoveEvent
(
QMouseEvent
*
event
);
protected
slots
:
protected
slots
:
void
accept
();
void
accept
();
...
@@ -66,4 +69,5 @@ private:
...
@@ -66,4 +69,5 @@ private:
Person
*
personSelected_
;
Person
*
personSelected_
;
ContactMethod
*
number_
;
ContactMethod
*
number_
;
OnlyPersonProxyModel
*
contactProxyModel_
;
OnlyPersonProxyModel
*
contactProxyModel_
;
QPoint
mpos_
;
};
};
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment