Yann Leboulanger pushed to branch master at gajim / gajim

Commits:
8e144e46 by Yann Leboulanger at 2018-04-04T14:42:10+02:00
Use XMPP logo in add contact dialog for XMPP protocol. Fixes #9049

- - - - -
17ae4e4c by Yann Leboulanger at 2018-04-04T14:46:46+02:00
Hide protocol combobox when adding contacts if only XMPP is available

- - - - -


2 changed files:

- + gajim/data/icons/hicolor/scalable/status/xmpp.svg
- gajim/dialogs.py


Changes:

=====================================
gajim/data/icons/hicolor/scalable/status/xmpp.svg
=====================================
--- /dev/null
+++ b/gajim/data/icons/hicolor/scalable/status/xmpp.svg
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Generator: Adobe Illustrator 13.0.2, SVG Export Plug-In . SVG Version: 
6.00 Build 14948)  -->
+<!DOCTYPE svg  PUBLIC '-//W3C//DTD SVG 1.1//EN'  
'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'>
+<svg id="Layer_1" xmlns="http://www.w3.org/2000/svg"; xml:space="preserve" 
height="181.44px" viewBox="0 0 176.486 181.437" width="176.49px" version="1.1" 
y="0px" x="0px" xmlns:xlink="http://www.w3.org/1999/xlink"; 
enable-background="new 0 0 176.486 181.437">
+<linearGradient id="SVGID_1_" y2=".00048828" gradientUnits="userSpaceOnUse" 
x2="-1807.2" gradientTransform="translate(1916)" y1="125.86" x1="-1807.2">
+       <stop stop-color="#1b3967" offset=".011"/>
+       <stop stop-color="#13b5ea" offset=".467"/>
+       <stop stop-color="#002b5c" offset=".9945"/>
+</linearGradient>
+<path d="m136.29 14.189c0.077 1.313-1.786 0.968-1.786 2.293 0 38.551-44.72 
96.831-89.847 108.19v1.182c59.957-5.51 126.73-66.8 128.24-125.85l-36.6 14.189z" 
fill="url(#SVGID_1_)"/>
+<path d="m120.23 17.96c0.077 1.313 0.121 2.633 0.121 3.958 0 38.551-30.7 
90.497-75.827 101.86v1.637c59.065-3.823 105.81-63.023 105.81-109.2 
0-2.375-0.125-4.729-0.371-7.056l-29.73 8.796z" fill="#E96D1F"/>
+<linearGradient id="SVGID_2_" y2="1.279e-13" gradientUnits="userSpaceOnUse" 
x2="-1073.2" gradientTransform="matrix(-1 0 0 1 -1008.2 0)" y1="126.85" 
x1="-1073.2">
+       <stop stop-color="#1b3967" offset=".011"/>
+       <stop stop-color="#13b5ea" offset=".467"/>
+       <stop stop-color="#002b5c" offset=".9945"/>
+</linearGradient>
+<path d="m150.34 8.76l-7.833 2.625c0.041 0.963 0.191 2.203 0.191 3.173 0 
41.219-37.272 98.205-87.274 107.12-3.243 1.089-7.538 2.077-10.93 
2.932v1.639c68.344-8.66 111.18-71.719 105.84-117.49z" fill="#D9541E"/>
+<path d="m36.599 14.189c-0.077 1.313 1.787 0.968 1.787 2.293 0 38.551 46.558 
97.366 91.688 108.73v1.639c-59.953-5.52-128.56-67.8-130.07-126.85l36.599 
14.189z" fill="url(#SVGID_2_)"/>
+<path d="m54.731 18.932c-0.076 1.313-0.12 2.63-0.12 3.957 0 38.551 30.699 
90.497 75.827 101.86v1.639c-59.044-2.79-105.81-63.024-105.81-109.2 0-2.375 
0.128-4.729 0.371-7.056l29.73 8.798z" fill="#A0CE67"/>
+<path d="m24.713 9.583l7.617 2.722c-0.041 0.962-0.066 2.254-0.066 3.225 0 
41.219 37.271 98.204 87.272 107.12 3.245 1.088 7.538 2.077 10.932 
2.931v1.638c-65.254-5.56-111.1-71.866-105.76-117.64z" fill="#439639"/>
+       <path d="m14.576 166.71l-13.388-14.65h11.643l9.127 10.268 
9.129-10.268h11.643l-13.387 14.646 14.401 14.728h-12.09l-9.697-10.67-9.693 
10.67h-12.092l14.404-14.73z"/>
+       <path d="m47.096 152.06h13.836l10.183 18.905 
10.183-18.905h13.832v29.374h-8.762v-21.096h-0.08l-11.807 
21.096h-6.733l-11.807-21.096h-0.082v21.096h-8.764v-29.37z"/>
+       <path d="m101.25 152.06h24.546c8.559 0 10.628 4.302 10.628 
10.063v2.516c0 4.381-1.908 9.41-8.275 9.41h-17.894v7.385h-9.005v-29.38zm9 
14.69h13.997c2.109 0 2.924-1.377 
2.924-3.123v-1.135c0-1.99-0.976-3.127-3.694-3.127h-13.227v7.38z"/>
+       <path d="m141.31 152.06h24.546c8.561 0 10.63 4.302 10.63 10.063v2.516c0 
4.381-1.907 9.41-8.275 9.41h-17.893v7.385h-9.008v-29.38zm9.01 14.69h13.996c2.11 
0 2.922-1.377 2.922-3.123v-1.135c0-1.99-0.974-3.127-3.693-3.127h-13.225v7.38z"/>
+</svg>


=====================================
gajim/dialogs.py
=====================================
--- a/gajim/dialogs.py
+++ b/gajim/dialogs.py
@@ -937,8 +937,7 @@ class AddNewContactWindow:
         uf_type = {'jabber': 'XMPP', 'aim': 'AIM', 'gadu-gadu': 'Gadu Gadu',
             'icq': 'ICQ', 'msn': 'MSN', 'yahoo': 'Yahoo'}
         # Jabber as first
-        online_icon = gtkgui_helpers.get_iconset_name_for('online')
-        liststore.append(['XMPP', online_icon, 'jabber'])
+        liststore.append(['XMPP', 'xmpp', 'jabber'])
         for type_ in self.agents:
             if type_ == 'jabber':
                 continue
@@ -1018,6 +1017,9 @@ class AddNewContactWindow:
             self.account_combobox.set_model(liststore)
             self.account_combobox.set_active(0)
 
+        if len(self.agents) == 1:
+            self.protocol_hbox.hide()
+
         if self.account:
             message_buffer = self.message_textview.get_buffer()
             msg = helpers.from_one_line(helpers.get_subscription_request_msg(



View it on GitLab: 
https://dev.gajim.org/gajim/gajim/compare/dc58586a7ad51ad8447c1a9ada257a2a572b23fa...17ae4e4ccc14b2c72c98da0215b698a7ed98c06c

---
View it on GitLab: 
https://dev.gajim.org/gajim/gajim/compare/dc58586a7ad51ad8447c1a9ada257a2a572b23fa...17ae4e4ccc14b2c72c98da0215b698a7ed98c06c
You're receiving this email because of your account on dev.gajim.org.
_______________________________________________
Commits mailing list
[email protected]
https://lists.gajim.org/cgi-bin/listinfo/commits

Reply via email to