Skip to content
Snippets Groups Projects
Commit 9c0ea510 authored by Andreas Traczyk's avatar Andreas Traczyk
Browse files

smartlist: use qml native placeholder

Change-Id: Iada72f807be439c6033a3b22469f5424b324e1a5
parent b1a7ba7f
No related branches found
No related tags found
No related merge requests found
......@@ -101,11 +101,6 @@ Popup {
onContactSearchBarTextChanged: {
ContactAdapter.setSearchFilter(text)
}
Component.onCompleted: {
contactPickerContactSearchBar.setPlaceholderString(
qsTr("Search contacts"))
}
}
ListView {
......
......@@ -27,11 +27,6 @@ Rectangle {
signal contactSearchBarTextChanged(string text)
function setPlaceholderString(str) {
placeholderTextForSearchBar.text = str
}
// Hack - there is no real way now to make TextField lose its focus,
// unless transfer it to other component.
function clearFocus() {
......@@ -80,22 +75,12 @@ Rectangle {
width: contactSearchBarRect.width - searchIconImage.width - 10
height: contactSearchBarRect.height - 5
font.pointSize: JamiTheme.textFontSize - 1
font.pointSize: JamiTheme.textFontSize
selectByMouse: true
selectionColor: JamiTheme.contactSearchBarPlaceHolderTextFontColor
Text {
id: placeholderTextForSearchBar
anchors.verticalCenter: contactSearchBar.verticalCenter
anchors.left: contactSearchBar.left
anchors.leftMargin: 10
text: JamiStrings.contactSearchConversation
font.pointSize: JamiTheme.textFontSize
color: JamiTheme.contactSearchBarPlaceHolderTextFontColor
visible: !contactSearchBar.text && !contactSearchBar.activeFocus
}
placeholderText: JamiStrings.contactSearchConversation
placeholderTextColor: JamiTheme.contactSearchBarPlaceHolderTextFontColor
background: Rectangle {
id: searchBarBackground
......
......@@ -68,8 +68,6 @@ Rectangle {
function accountChangedUIReset() {
contactSearchBar.clearText()
contactSearchBar.setPlaceholderString(
JamiStrings.contactSearchConversation)
sidePanelTabBar.converstationTabDown = true
sidePanelTabBar.invitationTabDown = false
}
......
......@@ -78,8 +78,6 @@ TabBar {
function showConversations() {
ConversationsAdapter.setConversationFilter("")
contactSearchBar.setPlaceholderString(
JamiStrings.contactSearchConversation)
pageOne.down = true
pageTwo.down = false
setCurrentUidSmartListModelIndex()
......@@ -199,8 +197,6 @@ TabBar {
function showRequests() {
ConversationsAdapter.setConversationFilter("PENDING")
contactSearchBar.setPlaceholderString(
JamiStrings.contactSearchInvitations)
pageTwo.down = true
pageOne.down = false
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment