changeset 145:654b00fa3fdc

core (common): renamed JidWidget to JidItem to avoid name conflict with XMLUI
author Goffi <goffi@goffi.org>
date Sat, 14 Apr 2018 16:35:59 +0200
parents ae58f84fe4e6
children 87eebe4628b8
files cagou/core/common.py cagou/kv/common.kv cagou/plugins/plugin_wid_chat.py
diffstat 3 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/cagou/core/common.py	Sat Apr 14 16:02:54 2018 +0200
+++ b/cagou/core/common.py	Sat Apr 14 16:35:59 2018 +0200
@@ -38,13 +38,13 @@
     pass
 
 
-class JidWidget(ButtonBehavior, BoxLayout):
+class JidItem(ButtonBehavior, BoxLayout):
 
     def __init__(self, jid, profile, **kwargs):
         self.jid = jid
         self.profile = profile
         self.nick = kwargs.get('nick')
-        super(JidWidget, self).__init__(**kwargs)
+        super(JidItem, self).__init__(**kwargs)
 
     def getImage(self, wid):
         host = G.host
--- a/cagou/kv/common.kv	Sat Apr 14 16:02:54 2018 +0200
+++ b/cagou/kv/common.kv	Sat Apr 14 16:35:59 2018 +0200
@@ -15,7 +15,7 @@
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 
-<JidWidget>:
+<JidItem>:
     size_hint: None, None
     height: dp(70)
     canvas.before:
--- a/cagou/plugins/plugin_wid_chat.py	Sat Apr 14 16:02:54 2018 +0200
+++ b/cagou/plugins/plugin_wid_chat.py	Sat Apr 14 16:35:59 2018 +0200
@@ -32,7 +32,7 @@
 from sat_frontends.tools import jid
 from cagou.core import cagou_widget
 from cagou.core.image import Image
-from cagou.core.common import SymbolButton, JidWidget
+from cagou.core.common import SymbolButton, JidItem
 from kivy.uix.dropdown import DropDown
 from cagou import G
 import mimetypes
@@ -308,7 +308,7 @@
             for jid_, jid_data in comp_data:
                 nick = jid_data.get(u'nick', u'')
                 if text in jid_.bare or text in nick.lower():
-                    btn = JidWidget(
+                    btn = JidItem(
                         jid = jid_.bare,
                         profile = profile,
                         size_hint = (0.5, None),