Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
sakia
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab 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
clients
python
sakia
Commits
add30b3d
Commit
add30b3d
authored
5 years ago
by
Vincent Texier
Browse files
Options
Downloads
Patches
Plain Diff
[fix] fix search_user view translation
parent
ac68a520
No related branches found
No related tags found
1 merge request
!775
0.50.0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/sakia/gui/sub/search_user/view.py
+5
-4
5 additions, 4 deletions
src/sakia/gui/sub/search_user/view.py
with
5 additions
and
4 deletions
src/sakia/gui/sub/search_user/view.py
+
5
−
4
View file @
add30b3d
from
PyQt5.QtWidgets
import
QWidget
,
QComboBox
,
QCompleter
from
PyQt5.QtCore
import
QT_TRANSLATE_NOOP
,
pyqtSignal
,
Qt
,
QStringListModel
from
PyQt5.QtCore
import
QT_TRANSLATE_NOOP
,
pyqtSignal
,
Qt
,
QStringListModel
,
QCoreApplication
from
sakia.data.entities
import
Contact
from
.search_user_uic
import
Ui_SearchUserWidget
import
re
...
...
@@ -12,7 +12,7 @@ class SearchUserView(QWidget, Ui_SearchUserWidget):
"""
_search_placeholder
=
QT_TRANSLATE_NOOP
(
"
SearchUser
Widget
"
,
"
Research a pubkey, an uid...
"
"
SearchUser
View
"
,
"
Research a pubkey, an uid...
"
)
search_requested
=
pyqtSignal
(
str
)
reset_requested
=
pyqtSignal
()
...
...
@@ -23,8 +23,9 @@ class SearchUserView(QWidget, Ui_SearchUserWidget):
super
().
__init__
(
parent
)
self
.
setupUi
(
self
)
# Default text when combo lineEdit is empty
res
=
QCoreApplication
.
translate
(
"
SearchUserView
"
,
SearchUserView
.
_search_placeholder
)
self
.
combobox_search
.
lineEdit
().
setPlaceholderText
(
self
.
tr
(
SearchUserView
.
_search_placeholder
)
res
)
# add combobox events
self
.
combobox_search
.
lineEdit
().
returnPressed
.
connect
(
self
.
search
)
...
...
@@ -52,7 +53,7 @@ class SearchUserView(QWidget, Ui_SearchUserWidget):
text
=
self
.
combobox_search
.
lineEdit
().
text
()
self
.
combobox_search
.
lineEdit
().
clear
()
self
.
combobox_search
.
lineEdit
().
setPlaceholderText
(
self
.
tr
(
"
Looking for {0}...
"
.
format
(
text
)
)
self
.
tr
(
"
Looking for {0}...
"
)
.
format
(
text
)
)
self
.
search_requested
.
emit
(
text
)
...
...
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