diff --git a/.gitignore b/.gitignore index c86a7cf1..85b62965 100644 --- a/.gitignore +++ b/.gitignore @@ -21,4 +21,4 @@ build pyan/ .buildozer/ bin/ -src/images/default_identicon/ \ No newline at end of file +src/images/kivy/default_identicon/*png \ No newline at end of file diff --git a/python3_requirements.txt b/python3_requirements.txt index 2f963acf..76abe49a 100644 --- a/python3_requirements.txt +++ b/python3_requirements.txt @@ -9,7 +9,8 @@ isort==4.3.21 Kivy==1.11.1 Kivy-Garden==0.1.4 kivy-garden.qrcode==2019.914 -kivymd==0.104.0 +#-e git+https://github.com/surbhicis/KivyMD-1#egg=kivymd +-e git+https://github.com/navjotcis/KivyMD#egg=kivymd lazy-object-proxy==1.4.3 mccabe==0.6.1 numpy==1.18.4 diff --git a/src/.buildozer/android/platform/python-for-android-new-toolchain b/src/.buildozer/android/platform/python-for-android-new-toolchain deleted file mode 160000 index 5aa322da..00000000 --- a/src/.buildozer/android/platform/python-for-android-new-toolchain +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 5aa322da9179dae305fde5af1db516c1ad9baea4 diff --git a/src/bitmessagekivy/android/python-for-android/recipes/kivymd/__init__.py b/src/bitmessagekivy/android/python-for-android/recipes/kivymd/__init__.py deleted file mode 100644 index 5a29bba7..00000000 --- a/src/bitmessagekivy/android/python-for-android/recipes/kivymd/__init__.py +++ /dev/null @@ -1,41 +0,0 @@ -""" -src/bitmessagekivy/android/python-for-android/recipes/kivymd/__init__.py -================================= -""" -# pylint: disable=import-error -from os.path import join - -from pythonforandroid.recipe import PythonRecipe -# from pythonforandroid.util import ensure_dir - - -class KivyMDRecipe(PythonRecipe): - """This recipe installs KivyMD into the android dist from source""" - version = 'master' - url = 'https://github.com/surbhicis/kivymd/archive/master.zip' - depends = ['kivy'] - site_packages_name = 'kivymd' - call_hostpython_via_targetpython = False - - def should_build(self, arch): # pylint: disable=no-self-use, unused-argument - """Method helps to build the application""" - return True - - def get_recipe_env(self, arch): - """Method is used for getting all the env paths""" - env = super(KivyMDRecipe, self).get_recipe_env(arch) - env['PYTHON_ROOT'] = self.ctx.get_python_install_dir() - env['CFLAGS'] += ' -I' + env['PYTHON_ROOT'] + '/include/python2.7' - env['LDFLAGS'] += ' -L' + env['PYTHON_ROOT'] + '/lib' + \ - ' -lpython2.7' - if 'sdl2' in self.ctx.recipe_build_order: - env['USE_SDL2'] = '1' - env['KIVY_SDL2_PATH'] = ':'.join([ - join(self.ctx.bootstrap.build_dir, 'jni', 'SDL', 'include'), - join(self.ctx.bootstrap.build_dir, 'jni', 'SDL2_image'), - join(self.ctx.bootstrap.build_dir, 'jni', 'SDL2_mixer'), - join(self.ctx.bootstrap.build_dir, 'jni', 'SDL2_ttf'), ]) - return env - - -recipe = KivyMDRecipe() diff --git a/src/bitmessagekivy/android/python-for-android/recipes/kivymd/kivymd-fix-dev-compatibility.patch b/src/bitmessagekivy/android/python-for-android/recipes/kivymd/kivymd-fix-dev-compatibility.patch deleted file mode 100644 index bc8d5dee..00000000 --- a/src/bitmessagekivy/android/python-for-android/recipes/kivymd/kivymd-fix-dev-compatibility.patch +++ /dev/null @@ -1,36 +0,0 @@ -diff -Naurp KivyMD.orig/kivymd/button.py KivyMD/kivymd/button.py ---- KivyMD.orig/kivymd/button.py 2017-08-25 13:12:34.000000000 +0200 -+++ KivyMD/kivymd/button.py 2018-07-10 10:37:55.719440354 +0200 -@@ -175,7 +175,8 @@ class BaseButton(ThemableBehavior, Butto - self._current_button_color = self.md_bg_color_disabled - else: - self._current_button_color = self.md_bg_color -- super(BaseButton, self).on_disabled(instance, value) -+ # To add compatibility to last kivy (disabled is now an Alias property) -+ # super(BaseButton, self).on_disabled(instance, value) - - - class BasePressedButton(BaseButton): -diff -Naurp KivyMD.orig/kivymd/selectioncontrols.py KivyMD/kivymd/selectioncontrols.py ---- KivyMD.orig/kivymd/selectioncontrols.py 2017-08-25 13:12:34.000000000 +0200 -+++ KivyMD/kivymd/selectioncontrols.py 2018-07-10 10:40:06.971439102 +0200 -@@ -45,6 +45,7 @@ Builder.load_string(''' - pos: self.pos - - : -+ _thumb_pos: (self.right - dp(12), self.center_y - dp(12)) if self.active else (self.x - dp(12), self.center_y - dp(12)) - canvas.before: - Color: - rgba: self._track_color_disabled if self.disabled else \ -diff -Naurp KivyMD.orig/kivymd/tabs.py KivyMD/kivymd/tabs.py ---- KivyMD.orig/kivymd/tabs.py 2017-08-25 13:12:34.000000000 +0200 -+++ KivyMD/kivymd/tabs.py 2018-07-10 10:39:20.603439544 +0200 -@@ -185,7 +185,7 @@ class MDBottomNavigationBar(ThemableBeha - - class MDTabHeader(MDFlatButton): - """ Internal widget for headers based on MDFlatButton""" -- -+ - width = BoundedNumericProperty(dp(0), min=dp(72), max=dp(264), errorhandler=lambda x: dp(72)) - tab = ObjectProperty(None) - panel = ObjectProperty(None) diff --git a/src/bitmessagekivy/kv/common_widgets.kv b/src/bitmessagekivy/kv/common_widgets.kv index 3865f9c8..bc10222c 100644 --- a/src/bitmessagekivy/kv/common_widgets.kv +++ b/src/bitmessagekivy/kv/common_widgets.kv @@ -1,5 +1,5 @@ : - source: './images/down-arrow.png' if self.parent.is_open == True else './images/right-arrow.png' + source: app.image_path +('/down-arrow.png' if self.parent.is_open == True else '/right-arrow.png') size: 15, 15 x: self.parent.x + self.parent.width - self.width - 5 y: self.parent.y + self.parent.height/2 - self.height + 5 diff --git a/src/bitmessagekivy/kv/composer.kv b/src/bitmessagekivy/kv/composer.kv index e6f2f1ef..4931fd56 100644 --- a/src/bitmessagekivy/kv/composer.kv +++ b/src/bitmessagekivy/kv/composer.kv @@ -18,6 +18,9 @@ multiline: False required: True helper_text_mode: "on_error" + canvas.before: + Color: + rgba: (0,0,0,1) BoxLayout: size_hint_y: None @@ -66,6 +69,9 @@ size_hint_y: None multiline: False helper_text_mode: "on_error" + canvas.before: + Color: + rgba: (0,0,0,1) MyMDTextField: id: body @@ -75,6 +81,9 @@ font_size: '15sp' required: True helper_text_mode: "on_error" + canvas.before: + Color: + rgba: (0,0,0,1) BoxLayout: spacing:50 diff --git a/src/bitmessagekivy/kv/maildetail.kv b/src/bitmessagekivy/kv/maildetail.kv index 714e56b6..3d51f657 100644 --- a/src/bitmessagekivy/kv/maildetail.kv +++ b/src/bitmessagekivy/kv/maildetail.kv @@ -74,4 +74,7 @@ line_color_focus: [0,0,0,0] markup: True font_size: '15sp' + canvas.before: + Color: + rgba: (0,0,0,1) Loader: \ No newline at end of file diff --git a/src/bitmessagekivy/kv/payment.kv b/src/bitmessagekivy/kv/payment.kv index 847ee698..542e8e0e 100644 --- a/src/bitmessagekivy/kv/payment.kv +++ b/src/bitmessagekivy/kv/payment.kv @@ -21,21 +21,21 @@ ProductLayout: heading_text: "Gas (Play Billing Codelab)" price_text: "$0.99" - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/buynew1.png" + source: app.image_path + "/payment/buynew1.png" description_text: "Buy gasoline to ride!" product_id: "SKUGASBILLING" ProductLayout: heading_text: "Upgrade your car (Play Billing Codelab)" price_text: "$1.49" - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/buynew1.png" + source: app.image_path + "/payment/buynew1.png" description_text: "Buy a premium outfit for your car!" product_id: "SKUUPGRADECAR" ProductLayout: heading_text: "Month in gold status (Play Billing Codelab)" price_text: "$0.99" - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/buynew1.png" + source: app.image_path + "/payment/buynew1.png" description_text: "Enjoy a gold status for a month!" product_id: "SKUMONTHLYGOLD" @@ -45,7 +45,7 @@ ProductLayout: heading_text: "Gas (Play Billing Codelab)" price_text: "$0.99" - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/buynew1.png" + source: app.image_path + "/payment/buynew1.png" description_text: "Buy gasoline to ride!" product_id: "SKUONETIMEGAS" @@ -55,14 +55,14 @@ ProductLayout: heading_text: "Gas (Play Billing Codelab)" price_text: "$0.99" - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/buynew1.png" + source: app.image_path + "/payment/buynew1.png" description_text: "Buy gasoline to ride!" product_id: "SKUANNUALGAS" ProductLayout: heading_text: "Year in gold status (Play Billing Codelab)" price_text: "$10.99" - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/buynew1.png" + source: app.image_path + "/payment/buynew1.png" description_text: "Enjoy a gold status for a year!" product_id: "SKUANNUALGOLD" @@ -232,22 +232,22 @@ height:self.minimum_height ListItemWithLabel: - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/gplay.png" + source: app.image_path + "/payment/gplay.png" text: "Google Play" method_name: "gplay" recent: True ListItemWithLabel: - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/btc.png" + source: app.image_path + "/payment/btc.png" text: "BTC" method_name: "btc" ListItemWithLabel: - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/paypal.png" + source: app.image_path + "/payment/paypal.png" text: "Paypal" method_name: "som" ListItemWithLabel: - source: "/home/surbhi/Downloads/peter3/PyBitmessage/src/images/buy.png" + source: app.image_path + "/payment/buy.png" text: "One more method" method_name: "omm" \ No newline at end of file diff --git a/src/bitmessagekivy/kv/popup.kv b/src/bitmessagekivy/kv/popup.kv index e8642f8d..8d2ddd04 100644 --- a/src/bitmessagekivy/kv/popup.kv +++ b/src/bitmessagekivy/kv/popup.kv @@ -6,7 +6,7 @@ disabled: True background_disabled_normal: "White.png" Image: - source: './images/loader.zip' + source: app.image_path + '/loader.zip' anim_delay: 0 #mipmap: True size: root.size @@ -18,7 +18,7 @@ height: 2*(label.height + address.height) + 10 width :app.window_size[0] - (app.window_size[0]/10 if app.app_platform == 'android' else app.window_size[0]/4) title: 'add contact\'s' - background: './images/popup.jpeg' + background: app.image_path + '/popup.jpeg' title_size: sp(20) title_color: 0.4, 0.3765, 0.3451, 1 auto_dismiss: False @@ -94,7 +94,7 @@ size_hint : (None,None) height: 4*(add_label.height) width :app.window_size[0] - (app.window_size[0]/10 if app.app_platform == 'android' else app.window_size[0]/4) - background: './images/popup.jpeg' + background: app.image_path + '/popup.jpeg' separator_height: 0 auto_dismiss: False BoxLayout: @@ -190,7 +190,7 @@ size_hint : (None,None) height: 4.5*(myaddr_label.height+ my_add_btn.children[0].height) width :app.window_size[0] - (app.window_size[0]/10 if app.app_platform == 'android' else app.window_size[0]/4) - background: './images/popup.jpeg' + background: app.image_path + '/popup.jpeg' auto_dismiss: False separator_height: 0 BoxLayout: @@ -276,7 +276,7 @@ size_hint : (None,None) height: 1.3*(popup_label.height+ my_add_btn.children[0].height) width :app.window_size[0] - (app.window_size[0]/10 if app.app_platform == 'android' else app.window_size[0]/4) - background: './images/popup.jpeg' + background: app.image_path + '/popup.jpeg' auto_dismiss: False separator_height: 0 BoxLayout: @@ -337,7 +337,7 @@ size_hint : (None,None) # height: 2*(sd_label.height+ sd_btn.children[0].height) width :app.window_size[0] - (app.window_size[0]/10 if app.app_platform == 'android' else app.window_size[0]/4) - background: './images/popup.jpeg' + background: app.image_path + '/popup.jpeg' auto_dismiss: False separator_height: 0 BoxLayout: diff --git a/src/bitmessagekivy/main.kv b/src/bitmessagekivy/main.kv index f0f2bf79..d52de7da 100644 --- a/src/bitmessagekivy/main.kv +++ b/src/bitmessagekivy/main.kv @@ -65,6 +65,7 @@ height: "200dp" MDIconButton: + id: file_manager icon: "file-image" x: root.parent.x + dp(10) pos_hint: {"top": 1, 'right': 1} @@ -73,6 +74,8 @@ # md_bg_color: app.theme_cls.primary_color theme_text_color: "Custom" text_color: app.theme_cls.primary_color + opacity: 1 if app.current_address_label() else 0 + disabled: False if app.current_address_label() else True BoxLayout: id: top_box @@ -322,6 +325,9 @@ NavigationLayout: halign: 'center' font_size: dp(15) bold: True + canvas.before: + Color: + rgba: (0,0,0,1) # MDLabel: # size_hint_y: None # font_style: 'Body1' diff --git a/src/bitmessagekivy/mpybit.py b/src/bitmessagekivy/mpybit.py index b7b4b0ee..c2185483 100644 --- a/src/bitmessagekivy/mpybit.py +++ b/src/bitmessagekivy/mpybit.py @@ -108,6 +108,7 @@ from kivy.utils import platform from kivymd.uix.button import MDIconButton from kivymd.uix.dialog import MDDialog from kivymd.uix.label import MDLabel +from kivymd.uix.button import MDFlatButton from kivymd.uix.list import ( ILeftBody, ILeftBodyTouch, @@ -134,7 +135,6 @@ from semaphores import kivyuisignaler import state from addresses import decodeAddress -from kivy.uix.modalview import ModalView from datetime import datetime from kivymd.uix.behaviors.elevation import RectangularElevationBehavior from kivymd.uix.bottomsheet import MDCustomBottomSheet @@ -155,6 +155,8 @@ KVFILES = [ 'chat_room', 'chat_list' ] +ThemeClsColor = [0.12, 0.58, 0.95, 1] + def toast(text): """Method will display the toast message""" @@ -291,10 +293,10 @@ class Inbox(Screen): meny = TwoLineAvatarIconListItem( text=item['text'], secondary_text=item['secondary_text'], theme_text_color='Custom', - text_color=NavigateApp().theme_cls.primary_color) + text_color=ThemeClsColor) meny._txt_right_pad = dp(70) meny.add_widget(AvatarSampleWidget( - source='./images/text_images/{}.png'.format( + source= state.imageDir +'/text_images/{}.png'.format( avatarImageFirstLetter(item['secondary_text'].strip())))) meny.bind(on_press=partial(self.inbox_detail, item['msgid'])) meny.add_widget(AddTimeWidget(item['received'])) @@ -477,14 +479,14 @@ class MyAddress(Screen): meny = CustomTwoLineAvatarIconListItem( text=item['text'], secondary_text=item['secondary_text'], theme_text_color='Custom' if is_enable == 'true' else 'Primary', - text_color=NavigateApp().theme_cls.primary_color,) + text_color=ThemeClsColor,) meny._txt_right_pad = dp(70) try: meny.canvas.children[6].rgba = [0, 0, 0, 0] if is_enable == 'true' else [0.5, 0.5, 0.5, 0.5] except Exception: meny.canvas.children[9].rgba = [0, 0, 0, 0] if is_enable == 'true' else [0.5, 0.5, 0.5, 0.5] meny.add_widget(AvatarSampleWidget( - source='./images/text_images/{}.png'.format( + source= state.imageDir + '/text_images/{}.png'.format( avatarImageFirstLetter(item['text'].strip())))) meny.bind(on_press=partial( self.myadd_detail, item['secondary_text'], item['text'])) @@ -494,7 +496,7 @@ class MyAddress(Screen): size=[85 if platform == 'android' else 50, 60], text='Active', halign='center', font_style='Body1', theme_text_color='Custom', - text_color=NavigateApp().theme_cls.primary_color + text_color=ThemeClsColor ) badge_obj.font_size = '13sp' meny.add_widget(badge_obj) @@ -527,16 +529,25 @@ class MyAddress(Screen): p.set_address(fromaddress, label) else: width = .8 if platform == 'android' else .55 - msg_dialog = MDDialog( - text='Address is not currently active. Please click on Toggle button to active it.', - title='', size_hint=(width, .25), text_button_ok='Ok', - events_callback=self.callback_for_menu_items) - msg_dialog.open() + dialog_box=MDDialog( + text='Address is not currently active. Please click on Toggle button to active it.', + size_hint=(width, .25), + buttons=[ + MDFlatButton( + text="Ok", on_release=lambda x: callback_for_menu_items("Ok") + ), + ],) + dialog_box.open() - @staticmethod - def callback_for_menu_items(text_item, *arg): - """Callback of alert box""" - toast(text_item) + def callback_for_menu_items(text_item, *arg): + """Callback of alert box""" + dialog_box.dismiss() + toast(text_item) + + # @staticmethod + # def callback_for_menu_items(text_item, *arg): + # """Callback of alert box""" + # toast(text_item) def refresh_callback(self, *args): """Method updates the state of application, @@ -654,9 +665,9 @@ class AddressBook(Screen): for item in self.queryreturn[start_index:end_index]: meny = TwoLineAvatarIconListItem( text=item[0], secondary_text=item[1], theme_text_color='Custom', - text_color=NavigateApp().theme_cls.primary_color) + text_color=ThemeClsColor) meny.add_widget(AvatarSampleWidget( - source='./images/text_images/{}.png'.format( + source=state.imageDir + '/text_images/{}.png'.format( avatarImageFirstLetter(item[0].strip())))) meny.bind(on_press=partial( self.addBook_detail, item[1], item[0])) @@ -873,16 +884,25 @@ class DropDownWidget(BoxLayout): def address_error_message(self, msg): """Generates error message""" width = .8 if platform == 'android' else .55 - msg_dialog = MDDialog( + dialog_box=MDDialog( text=msg, - title='', size_hint=(width, .25), text_button_ok='Ok', - events_callback=self.callback_for_menu_items) - msg_dialog.open() + size_hint=(width, .25), + buttons=[ + MDFlatButton( + text="Ok", on_release=lambda x: callback_for_menu_items("Ok") + ), + ],) + dialog_box.open() - @staticmethod - def callback_for_menu_items(text_item, *arg): - """Callback of alert box""" - toast(text_item) + def callback_for_menu_items(text_item, *arg): + """Callback of alert box""" + dialog_box.dismiss() + toast(text_item) + + # @staticmethod + # def callback_for_menu_items(text_item, *arg): + # """Callback of alert box""" + # toast(text_item) def reset_composer(self): """Method will reset composer""" @@ -1265,10 +1285,10 @@ class Sent(Screen): meny = TwoLineAvatarIconListItem( text=item['text'], secondary_text=item['secondary_text'], theme_text_color='Custom', - text_color=NavigateApp().theme_cls.primary_color) + text_color=ThemeClsColor) meny._txt_right_pad = dp(70) meny.add_widget(AvatarSampleWidget( - source='./images/text_images/{}.png'.format( + source=state.imageDir + '/text_images/{}.png'.format( avatarImageFirstLetter(item['secondary_text'].strip())))) meny.bind(on_press=partial(self.sent_detail, item['ackdata'])) meny.add_widget(AddTimeWidget(item['senttime'])) @@ -1484,9 +1504,9 @@ class Trash(Screen): secondary_text=(item[2][:50] + '........' if len( subject) >= 50 else (subject + ',' + body)[0:50] + '........').replace('\t', '').replace(' ', ''), theme_text_color='Custom', - text_color=NavigateApp().theme_cls.primary_color) + text_color=ThemeClsColor) meny._txt_right_pad = dp(70) - img_latter = './images/text_images/{}.png'.format( + img_latter =state.imageDir + '/text_images/{}.png'.format( subject[0].upper() if (subject[0].upper() >= 'A' and subject[0].upper() <= 'Z') else '!') meny.add_widget(AvatarSampleWidget(source=img_latter)) meny.add_widget(AddTimeWidget(item[7])) @@ -1539,22 +1559,34 @@ class Trash(Screen): def delete_confirmation(self): """Show confirmation delete popup""" width = .8 if platform == 'android' else .55 - delete_msg_dialog = MDDialog( + dialog_box=MDDialog( text='Are you sure you want to delete this' ' message permanently from trash?', - title='', size_hint=(width, .25), - text_button_ok='Yes', - text_button_cancel='No', - events_callback=self.callback_for_delete_msg) - delete_msg_dialog.open() + buttons=[ + MDFlatButton( + text="Yes", on_release=lambda x: callback_for_delete_msg("Yes") + ), + MDFlatButton( + text="No",on_release=lambda x: callback_for_delete_msg("No"), + ), + ],) + dialog_box.open() - def callback_for_delete_msg(self, text_item, *arg): - """Getting the callback of alert box""" - if text_item == 'Yes': - self.delete_message_from_trash() - else: - toast(text_item) + def callback_for_delete_msg(text_item, *arg): + """Getting the callback of alert box""" + if text_item == 'Yes': + self.delete_message_from_trash() + else: + toast(text_item) + dialog_box.dismiss() + + # def callback_for_delete_msg(self, text_item, *arg): + # """Getting the callback of alert box""" + # if text_item == 'Yes': + # self.delete_message_from_trash() + # else: + # toast(text_item) def delete_message_from_trash(self): """Deleting message from trash""" @@ -1625,6 +1657,10 @@ class NavigateApp(MDApp): imgstatus = False count = 0 manager_open = False + file_manager = None + # state.imageDir = os.path.join(os.path.abspath(os.path.join(__file__ ,"../../..")),'images', 'kivy') + state.imageDir = os.path.join('./images', 'kivy') + image_path = state.imageDir def build(self): """Method builds the widget""" @@ -1658,7 +1694,7 @@ class NavigateApp(MDApp): def getCurrentAccountData(self, text): """Get Current Address Account Data""" - if os.path.exists('./images/default_identicon/{}.png'.format(text)): + if os.path.exists(state.imageDir + '/default_identicon/{}.png'.format(text)): self.load_selected_Image(text) else: self.set_identicon(text) @@ -1672,8 +1708,16 @@ class NavigateApp(MDApp): for nav_obj in self.root.ids.content_drawer.children[ 0].children[0].children[0].children: nav_obj.active = True if nav_obj.text == 'Inbox' else False + self.fileManagerSetting() Clock.schedule_once(self.setCurrentAccountData, 0.5) + def fileManagerSetting(self): + """This method is for file manager setting""" + if not self.root.ids.content_drawer.ids.file_manager.opacity and \ + self.root.ids.content_drawer.ids.file_manager.disabled: + self.root.ids.content_drawer.ids.file_manager.opacity = 1 + self.root.ids.content_drawer.ids.file_manager.disabled = False + def setCurrentAccountData(self, dt=0): """This method set the current accout data on all the screens""" self.root.ids.sc1.ids.ml.clear_widgets() @@ -1714,20 +1758,20 @@ class NavigateApp(MDApp): """Getting Default Account Data""" if BMConfigParser().addresses(): img = identiconGeneration.generate(BMConfigParser().addresses()[0]) - self.createFolder('./images/default_identicon/') + self.createFolder(state.imageDir + '/default_identicon/') if platform == 'android': # android_path = os.path.expanduser # ("~/user/0/org.test.bitapp/files/app/") - if not os.path.exists('./images/default_identicon/{}.png'.format( + if not os.path.exists(state.imageDir + '/default_identicon/{}.png'.format( BMConfigParser().addresses()[0])): android_path = os.path.join( os.environ['ANDROID_PRIVATE'] + '/app/') - img.texture.save('{1}/images/default_identicon/{0}.png'.format( + img.texture.save('{1}/kivy/default_identicon/{0}.png'.format( BMConfigParser().addresses()[0], android_path)) else: - if not os.path.exists('./images/default_identicon/{}.png'.format( + if not os.path.exists(state.imageDir + '/default_identicon/{}.png'.format( BMConfigParser().addresses()[0])): - img.texture.save('./images/default_identicon/{}.png'.format( + img.texture.save(state.imageDir + '/default_identicon/{}.png'.format( BMConfigParser().addresses()[0])) return BMConfigParser().addresses()[0] return 'Select Address' @@ -1745,17 +1789,17 @@ class NavigateApp(MDApp): def get_default_image(): """Getting default image on address""" if BMConfigParser().addresses(): - return './images/default_identicon/{}.png'.format( + return state.imageDir + '/default_identicon/{}.png'.format( BMConfigParser().addresses()[0]) - return './images/no_identicons.png' + return state.imageDir + '/no_identicons.png' @staticmethod def get_default_logo(): """Getting default logo image""" if BMConfigParser().addresses(): - return './images/default_identicon/{}.png'.format( + return state.imageDir + '/default_identicon/{}.png'.format( BMConfigParser().addresses()[0]) - return './images/drawer_logo1.png' + return state.imageDir + '/drawer_logo1.png' @staticmethod def addressexist(): @@ -2148,68 +2192,57 @@ class NavigateApp(MDApp): """This method open the file manager of local system""" from kivymd.uix.filemanager import MDFileManager - self.manager = ModalView(size_hint=(1, 1), auto_dismiss=False) - self.file_manager = MDFileManager( - exit_manager=self.exit_manager, - select_path=self.select_path, - previous=False, - ext=['.png', '.jpg'] - ) - self.manager.add_widget(self.file_manager) - # self.file_manager.show(os.environ["HOME"]) + if not self.file_manager: + self.file_manager = MDFileManager( + exit_manager=self.exit_manager, + select_path=self.select_path, + ext=['.png', '.jpg'] + ) + self.file_manager.previous = False + self.file_manager.current_path = '/' if platform == 'android': - from android.permissions import request_permissions, Permission - request_permissions([Permission.WRITE_EXTERNAL_STORAGE, Permission.READ_EXTERNAL_STORAGE]) - - # from android.storage import app_storage_path - # settings_path = app_storage_path() - # print('path1................................', settings_path) - - # from android.storage import primary_external_storage_path - # primary_ext_storage = primary_external_storage_path() - # print('path1................................', primary_ext_storage) - - # from android.storage import secondary_external_storage_path - # secondary_ext_storage = secondary_external_storage_path() - # print('path1................................', secondary_ext_storage) - - # from kivy.app import user_data_dir - # from os.path import dirname, join - # out = join(dirname(user_data_dir), 'DCIM') - # DCIM = join('/sdcard', 'DCIM') - self.file_manager.show(os.getenv('EXTERNAL_STORAGE') if platform == 'android' else os.environ["HOME"]) - # self.file_manager.show(os.getenv('EXTERNAL_STORAGE')) - self.manager_open = True - self.manager.open() + from android.permissions import request_permissions, Permission, check_permission + if check_permission(Permission.WRITE_EXTERNAL_STORAGE) and \ + check_permission(Permission.READ_EXTERNAL_STORAGE): + self.file_manager.show(os.getenv('EXTERNAL_STORAGE')) + self.manager_open = True + else: + request_permissions([Permission.WRITE_EXTERNAL_STORAGE, Permission.READ_EXTERNAL_STORAGE]) + else: + self.file_manager.show(os.environ["HOME"]) + self.manager_open = True def select_path(self, path): """This method is used to save the select image""" - from PIL import Image as PilImage - newImg = PilImage.open(path).resize((300, 300)) - if platform == 'android': - android_path = os.path.join( - os.environ['ANDROID_PRIVATE'] + '/app/') - newImg.save('{1}/images/default_identicon/{0}.png'.format( - state.association, android_path)) - else: - if not os.path.exists('./images/default_identicon/'): - os.makedirs('./images/default_identicon/') - newImg.save('./images/default_identicon/{0}.png'.format(state.association)) - self.load_selected_Image(state.association) + try: + from PIL import Image as PilImage + newImg = PilImage.open(path).resize((300, 300)) + if platform == 'android': + android_path = os.path.join( + os.environ['ANDROID_PRIVATE'] + '/app/') + newImg.save('{1}/kivy/default_identicon/{0}.png'.format( + state.association, android_path)) + else: + if not os.path.exists(state.imageDir + '/default_identicon/'): + os.makedirs(state.imageDir + '/default_identicon/') + newImg.save(state.imageDir + '/default_identicon/{0}.png'.format(state.association)) + self.load_selected_Image(state.association) + toast('Image changed') + except Exception: + toast('Exit') self.exit_manager() - toast('Image changed') def exit_manager(self, *args): """Called when the user reaches the root of the directory tree.""" - self.manager.dismiss() self.manager_open = False + self.file_manager.close() def load_selected_Image(self, curerentAddr): """This method load the selected image on screen""" top_box_obj = self.root.ids.content_drawer.ids.top_box.children[0] # spinner_img_obj = self.root.ids.content_drawer.ids.btn.children[1] # spinner_img_obj.source = top_box_obj.source ='./images/default_identicon/{0}.png'.format(curerentAddr) - top_box_obj.source = './images/default_identicon/{0}.png'.format(curerentAddr) + top_box_obj.source = state.imageDir + '/default_identicon/{0}.png'.format(curerentAddr) top_box_obj.reload() # spinner_img_obj.reload() @@ -2441,8 +2474,8 @@ class MailDetail(Screen): # pylint: disable=too-many-instance-attributes if len(data[0]) == 7: self.status = data[0][4] self.time_tag = ShowTimeHistoy(data[0][4]) if state.detailPageType == 'inbox' else ShowTimeHistoy(data[0][6]) - self.avatarImg = './images/avatar.png' if state.detailPageType == 'draft' else ( - './images/text_images/{0}.png'.format(avatarImageFirstLetter(self.subject.strip()))) + self.avatarImg = state.imageDir + '/avatar.png' if state.detailPageType == 'draft' else ( + state.imageDir + '/text_images/{0}.png'.format(avatarImageFirstLetter(self.subject.strip()))) self.timeinseconds = data[0][4] if state.detailPageType == 'inbox' else data[0][6] def delete_mail(self): @@ -2673,7 +2706,10 @@ class ShowQRCode(Screen): """Method used for showing QR Code""" self.ids.qr.clear_widgets() state.kivyapp.set_toolbar_for_QrCode() - from kivy_garden.qrcode import QRCodeWidget + try: + from kivy.garden.qrcode import QRCodeWidget + except Exception as e: + from kivy_garden.qrcode import QRCodeWidget try: address = self.manager.get_parent_window().children[0].address except Exception: @@ -2761,10 +2797,10 @@ class Draft(Screen): meny = TwoLineAvatarIconListItem( text='Draft', secondary_text=item['text'], theme_text_color='Custom', - text_color=NavigateApp().theme_cls.primary_color) + text_color=ThemeClsColor) meny._txt_right_pad = dp(70) meny.add_widget(AvatarSampleWidget( - source='./images/avatar.png')) + source=state.imageDir + '/avatar.png')) meny.bind(on_press=partial( self.draft_detail, item['ackdata'])) meny.add_widget(AddTimeWidget(item['senttime'])) @@ -2964,10 +3000,10 @@ class Allmails(Screen): subject) >= 50 else ( subject + ',' + body)[0:50] + '........').replace('\t', '').replace(' ', ''), theme_text_color='Custom', - text_color=NavigateApp().theme_cls.primary_color) + text_color=ThemeClsColor) meny._txt_right_pad = dp(70) meny.add_widget(AvatarSampleWidget( - source='./images/text_images/{}.png'.format( + source= state.imageDir +'/text_images/{}.png'.format( avatarImageFirstLetter(body.strip())))) meny.bind(on_press=partial( self.mail_detail, item[5], item[4])) @@ -3246,20 +3282,32 @@ class OneLineListTitle(OneLineListItem): def copymessageTitle(self, text): """this method is for displaying dialog box""" width = .8 if platform == 'android' else .55 - msg_dialog = MDDialog( + dialog_box=MDDialog( text=text, - title='', size_hint=(width, .25), - text_button_cancel='Cancel', - text_button_ok='Copy', - events_callback=self.callback_for_copy_title) - msg_dialog.open() + size_hint=(width, .25), + buttons=[ + MDFlatButton( + text="Copy", on_release=lambda x: callback_for_copy_title(text) + ), + MDFlatButton( + text="Cancel",on_release=lambda x: callback_for_copy_title(text), + ), + ],) + dialog_box.open() - @staticmethod - def callback_for_copy_title(text_item, *arg): - """Callback of alert box""" - if text_item == 'Copy': - Clipboard.copy(str(arg[0].text)) - toast(text_item) + def callback_for_copy_title(text_item, *arg): + """Callback of alert box""" + if text_item == 'Copy': + Clipboard.copy() + dialog_box.dismiss() + toast(text_item) + + # @staticmethod + # def callback_for_copy_title(text_item, *arg): + # """Callback of alert box""" + # if text_item == 'Copy': + # Clipboard.copy(str(arg[0].text)) + # toast(text_item) class ToAddrBoxlayout(BoxLayout): @@ -3340,9 +3388,9 @@ class ChatList(Screen): for item in self.queryreturn: meny = TwoLineAvatarIconListItem( text=item[0], secondary_text=item[1], theme_text_color='Custom', - text_color=NavigateApp().theme_cls.primary_color) + text_color=ThemeClsColor) meny.add_widget(AvatarSampleWidget( - source='./images/text_images/{}.png'.format( + source= state.imageDir + '/text_images/{}.png'.format( avatarImageFirstLetter(item[0].strip())))) meny.bind(on_release=partial( self.redirect_to_chat, item[0], item[1])) diff --git a/src/buildozer.spec b/src/buildozer.spec index df464e77..7410e96e 100644 --- a/src/buildozer.spec +++ b/src/buildozer.spec @@ -48,7 +48,8 @@ requirements = pillow, bitmsghash, #git+https://github.com/surbhicis/KivyMD-1.git, - git+https://github.com/surbhicis/KivyMD-1#egg=kivymd, + #git+https://github.com/surbhicis/KivyMD-1#egg=kivymd, + git+https://github.com/navjotcis/KivyMD#egg=kivymd, kivy-garden, qrcode, msgpack @@ -194,6 +195,9 @@ android.sdk = 20 # (list) Java classes to add as activities to the manifest. #android.add_activites = com.example.ExampleActivity +# (str) python-for-android branch to use, defaults to stable +# p4a.branch = master + # (str) OUYA Console category. Should be one of GAME or APP # If you leave this blank, OUYA support will not be enabled #android.ouya.category = GAME @@ -248,10 +252,10 @@ android.arch = arm64-v8a p4a.branch = develop # (str) python-for-android git clone directory (if empty, it will be automatically cloned from github) -#p4a.source_dir = +# p4a.source_dir = /home/cis/Music/androidp4a/python-for-android # (str) The directory in which python-for-android should look for your own build recipes (if any) -p4a.local_recipes = /home/surbhi/Downloads/peter3/PyBitmessage/src/bitmessagekivy/android/python-for-android/recipes/ +p4a.local_recipes = %(source.dir)s/bitmessagekivy/android/python-for-android/recipes/ # (str) Filename to the hook for p4a #p4a.hook = diff --git a/src/images/3.zip b/src/images/kivy/3.zip similarity index 100% rename from src/images/3.zip rename to src/images/kivy/3.zip diff --git a/src/images/kivy/account_multiple.png b/src/images/kivy/account_multiple.png new file mode 100644 index 00000000..11271619 Binary files /dev/null and b/src/images/kivy/account_multiple.png differ diff --git a/src/images/kivy/addressbook.png b/src/images/kivy/addressbook.png new file mode 100644 index 00000000..69424134 Binary files /dev/null and b/src/images/kivy/addressbook.png differ diff --git a/src/images/kivy/addressbookadd.png b/src/images/kivy/addressbookadd.png new file mode 100644 index 00000000..82af2f63 Binary files /dev/null and b/src/images/kivy/addressbookadd.png differ diff --git a/src/images/kivy/avatar.png b/src/images/kivy/avatar.png new file mode 100644 index 00000000..b006bfa2 Binary files /dev/null and b/src/images/kivy/avatar.png differ diff --git a/src/images/kivy/back-button.png b/src/images/kivy/back-button.png new file mode 100644 index 00000000..e260b08b Binary files /dev/null and b/src/images/kivy/back-button.png differ diff --git a/src/images/kivy/bitmessage.icns b/src/images/kivy/bitmessage.icns new file mode 100644 index 00000000..5fe52d4e Binary files /dev/null and b/src/images/kivy/bitmessage.icns differ diff --git a/src/images/black_cross.png b/src/images/kivy/black_cross.png similarity index 100% rename from src/images/black_cross.png rename to src/images/kivy/black_cross.png diff --git a/src/images/kivy/blacklist.png b/src/images/kivy/blacklist.png new file mode 100644 index 00000000..820065a4 Binary files /dev/null and b/src/images/kivy/blacklist.png differ diff --git a/src/images/kivy/blue-plus-icon-12.png b/src/images/kivy/blue-plus-icon-12.png new file mode 100644 index 00000000..f9007861 Binary files /dev/null and b/src/images/kivy/blue-plus-icon-12.png differ diff --git a/src/images/kivy/can-icon-16px.png b/src/images/kivy/can-icon-16px.png new file mode 100644 index 00000000..c649919f Binary files /dev/null and b/src/images/kivy/can-icon-16px.png differ diff --git a/src/images/kivy/can-icon-24px-green.png b/src/images/kivy/can-icon-24px-green.png new file mode 100644 index 00000000..652da9c0 Binary files /dev/null and b/src/images/kivy/can-icon-24px-green.png differ diff --git a/src/images/kivy/can-icon-24px-red.png b/src/images/kivy/can-icon-24px-red.png new file mode 100644 index 00000000..cf66fcbb Binary files /dev/null and b/src/images/kivy/can-icon-24px-red.png differ diff --git a/src/images/kivy/can-icon-24px-yellow.png b/src/images/kivy/can-icon-24px-yellow.png new file mode 100644 index 00000000..0a26470b Binary files /dev/null and b/src/images/kivy/can-icon-24px-yellow.png differ diff --git a/src/images/kivy/can-icon-24px.png b/src/images/kivy/can-icon-24px.png new file mode 100644 index 00000000..30f7313e Binary files /dev/null and b/src/images/kivy/can-icon-24px.png differ diff --git a/src/images/kivy/can-icon.ico b/src/images/kivy/can-icon.ico new file mode 100644 index 00000000..903bf3da Binary files /dev/null and b/src/images/kivy/can-icon.ico differ diff --git a/src/images/copy_text.png b/src/images/kivy/copy_text.png similarity index 100% rename from src/images/copy_text.png rename to src/images/kivy/copy_text.png diff --git a/src/images/kivy/default_identicon/BM-2cVBL4cpxW5p1EuK78huuRFj3nhbP9QdfL.png b/src/images/kivy/default_identicon/BM-2cVBL4cpxW5p1EuK78huuRFj3nhbP9QdfL.png new file mode 100644 index 00000000..8ddf4e6f Binary files /dev/null and b/src/images/kivy/default_identicon/BM-2cVBL4cpxW5p1EuK78huuRFj3nhbP9QdfL.png differ diff --git a/src/images/down-arrow.png b/src/images/kivy/down-arrow.png similarity index 100% rename from src/images/down-arrow.png rename to src/images/kivy/down-arrow.png diff --git a/src/images/kivy/drawer_logo1.png b/src/images/kivy/drawer_logo1.png new file mode 100644 index 00000000..4152cc40 Binary files /dev/null and b/src/images/kivy/drawer_logo1.png differ diff --git a/src/images/kivy/greenicon.png b/src/images/kivy/greenicon.png new file mode 100644 index 00000000..cedf9dc2 Binary files /dev/null and b/src/images/kivy/greenicon.png differ diff --git a/src/images/kivy/identities.png b/src/images/kivy/identities.png new file mode 100644 index 00000000..a6aae040 Binary files /dev/null and b/src/images/kivy/identities.png differ diff --git a/src/images/kivy/inbox.png b/src/images/kivy/inbox.png new file mode 100644 index 00000000..dc6a6f75 Binary files /dev/null and b/src/images/kivy/inbox.png differ diff --git a/src/images/kivy/kivymd_logo.png b/src/images/kivy/kivymd_logo.png new file mode 100644 index 00000000..ce39b0d4 Binary files /dev/null and b/src/images/kivy/kivymd_logo.png differ diff --git a/src/images/left_arrow.png b/src/images/kivy/left_arrow.png similarity index 100% rename from src/images/left_arrow.png rename to src/images/kivy/left_arrow.png diff --git a/src/images/loader.gif b/src/images/kivy/loader.gif similarity index 100% rename from src/images/loader.gif rename to src/images/kivy/loader.gif diff --git a/src/images/loader.zip b/src/images/kivy/loader.zip similarity index 100% rename from src/images/loader.zip rename to src/images/kivy/loader.zip diff --git a/src/images/kivy/me.jpg b/src/images/kivy/me.jpg new file mode 100644 index 00000000..f54c791f Binary files /dev/null and b/src/images/kivy/me.jpg differ diff --git a/src/images/kivy/networkstatus.png b/src/images/kivy/networkstatus.png new file mode 100644 index 00000000..b702ee85 Binary files /dev/null and b/src/images/kivy/networkstatus.png differ diff --git a/src/images/kivy/ngletteravatar/1.png b/src/images/kivy/ngletteravatar/1.png new file mode 100644 index 00000000..9436c7d2 Binary files /dev/null and b/src/images/kivy/ngletteravatar/1.png differ diff --git a/src/images/kivy/ngletteravatar/12.png b/src/images/kivy/ngletteravatar/12.png new file mode 100644 index 00000000..de894b4a Binary files /dev/null and b/src/images/kivy/ngletteravatar/12.png differ diff --git a/src/images/kivy/ngletteravatar/14.png b/src/images/kivy/ngletteravatar/14.png new file mode 100644 index 00000000..42b692dd Binary files /dev/null and b/src/images/kivy/ngletteravatar/14.png differ diff --git a/src/images/kivy/ngletteravatar/3.png b/src/images/kivy/ngletteravatar/3.png new file mode 100644 index 00000000..ad83cef2 Binary files /dev/null and b/src/images/kivy/ngletteravatar/3.png differ diff --git a/src/images/kivy/ngletteravatar/5.png b/src/images/kivy/ngletteravatar/5.png new file mode 100644 index 00000000..3875aace Binary files /dev/null and b/src/images/kivy/ngletteravatar/5.png differ diff --git a/src/images/kivy/ngletteravatar/56.png b/src/images/kivy/ngletteravatar/56.png new file mode 100644 index 00000000..33f038cf Binary files /dev/null and b/src/images/kivy/ngletteravatar/56.png differ diff --git a/src/images/kivy/ngletteravatar/65.png b/src/images/kivy/ngletteravatar/65.png new file mode 100644 index 00000000..fb608098 Binary files /dev/null and b/src/images/kivy/ngletteravatar/65.png differ diff --git a/src/images/kivy/ngletteravatar/8.png b/src/images/kivy/ngletteravatar/8.png new file mode 100644 index 00000000..dd2671e9 Binary files /dev/null and b/src/images/kivy/ngletteravatar/8.png differ diff --git a/src/images/kivy/ngletteravatar/90.png b/src/images/kivy/ngletteravatar/90.png new file mode 100644 index 00000000..7d1770ab Binary files /dev/null and b/src/images/kivy/ngletteravatar/90.png differ diff --git a/src/images/kivy/ngletteravatar/Galleryr_rcirclelogo_Small.jpg b/src/images/kivy/ngletteravatar/Galleryr_rcirclelogo_Small.jpg new file mode 100644 index 00000000..8e3b1c35 Binary files /dev/null and b/src/images/kivy/ngletteravatar/Galleryr_rcirclelogo_Small.jpg differ diff --git a/src/images/kivy/ngletteravatar/a.png b/src/images/kivy/ngletteravatar/a.png new file mode 100644 index 00000000..1c3bb8bf Binary files /dev/null and b/src/images/kivy/ngletteravatar/a.png differ diff --git a/src/images/kivy/ngletteravatar/b.png b/src/images/kivy/ngletteravatar/b.png new file mode 100644 index 00000000..462bf808 Binary files /dev/null and b/src/images/kivy/ngletteravatar/b.png differ diff --git a/src/images/kivy/ngletteravatar/c.png b/src/images/kivy/ngletteravatar/c.png new file mode 100644 index 00000000..180b7edc Binary files /dev/null and b/src/images/kivy/ngletteravatar/c.png differ diff --git a/src/images/kivy/ngletteravatar/d.png b/src/images/kivy/ngletteravatar/d.png new file mode 100644 index 00000000..9e983e4d Binary files /dev/null and b/src/images/kivy/ngletteravatar/d.png differ diff --git a/src/images/kivy/ngletteravatar/depositphotos_142729281-stock-illustration-letter-l-sign-design-template.jpg b/src/images/kivy/ngletteravatar/depositphotos_142729281-stock-illustration-letter-l-sign-design-template.jpg new file mode 100644 index 00000000..7630511f Binary files /dev/null and b/src/images/kivy/ngletteravatar/depositphotos_142729281-stock-illustration-letter-l-sign-design-template.jpg differ diff --git a/src/images/kivy/ngletteravatar/e.png b/src/images/kivy/ngletteravatar/e.png new file mode 100644 index 00000000..60961992 Binary files /dev/null and b/src/images/kivy/ngletteravatar/e.png differ diff --git a/src/images/kivy/ngletteravatar/g.png b/src/images/kivy/ngletteravatar/g.png new file mode 100644 index 00000000..762cc6fa Binary files /dev/null and b/src/images/kivy/ngletteravatar/g.png differ diff --git a/src/images/kivy/ngletteravatar/h.png b/src/images/kivy/ngletteravatar/h.png new file mode 100644 index 00000000..8f752952 Binary files /dev/null and b/src/images/kivy/ngletteravatar/h.png differ diff --git a/src/images/kivy/ngletteravatar/i.png b/src/images/kivy/ngletteravatar/i.png new file mode 100644 index 00000000..a89710ef Binary files /dev/null and b/src/images/kivy/ngletteravatar/i.png differ diff --git a/src/images/kivy/ngletteravatar/j.png b/src/images/kivy/ngletteravatar/j.png new file mode 100644 index 00000000..926de34c Binary files /dev/null and b/src/images/kivy/ngletteravatar/j.png differ diff --git a/src/images/kivy/ngletteravatar/k.png b/src/images/kivy/ngletteravatar/k.png new file mode 100644 index 00000000..77da163e Binary files /dev/null and b/src/images/kivy/ngletteravatar/k.png differ diff --git a/src/images/kivy/ngletteravatar/l.png b/src/images/kivy/ngletteravatar/l.png new file mode 100644 index 00000000..e6112f2a Binary files /dev/null and b/src/images/kivy/ngletteravatar/l.png differ diff --git a/src/images/kivy/ngletteravatar/m.png b/src/images/kivy/ngletteravatar/m.png new file mode 100644 index 00000000..c93554a1 Binary files /dev/null and b/src/images/kivy/ngletteravatar/m.png differ diff --git a/src/images/kivy/ngletteravatar/n.png b/src/images/kivy/ngletteravatar/n.png new file mode 100644 index 00000000..8158a1e4 Binary files /dev/null and b/src/images/kivy/ngletteravatar/n.png differ diff --git a/src/images/kivy/ngletteravatar/o.png b/src/images/kivy/ngletteravatar/o.png new file mode 100644 index 00000000..729a82a6 Binary files /dev/null and b/src/images/kivy/ngletteravatar/o.png differ diff --git a/src/images/kivy/ngletteravatar/p.png b/src/images/kivy/ngletteravatar/p.png new file mode 100644 index 00000000..b3adb0ce Binary files /dev/null and b/src/images/kivy/ngletteravatar/p.png differ diff --git a/src/images/kivy/ngletteravatar/r.png b/src/images/kivy/ngletteravatar/r.png new file mode 100644 index 00000000..1b64b8ee Binary files /dev/null and b/src/images/kivy/ngletteravatar/r.png differ diff --git a/src/images/kivy/ngletteravatar/s.png b/src/images/kivy/ngletteravatar/s.png new file mode 100644 index 00000000..8813d11a Binary files /dev/null and b/src/images/kivy/ngletteravatar/s.png differ diff --git a/src/images/kivy/ngletteravatar/t.jpg b/src/images/kivy/ngletteravatar/t.jpg new file mode 100644 index 00000000..20932aad Binary files /dev/null and b/src/images/kivy/ngletteravatar/t.jpg differ diff --git a/src/images/kivy/ngletteravatar/u.png b/src/images/kivy/ngletteravatar/u.png new file mode 100644 index 00000000..6af53add Binary files /dev/null and b/src/images/kivy/ngletteravatar/u.png differ diff --git a/src/images/kivy/ngletteravatar/v.png b/src/images/kivy/ngletteravatar/v.png new file mode 100644 index 00000000..aaaf191e Binary files /dev/null and b/src/images/kivy/ngletteravatar/v.png differ diff --git a/src/images/kivy/ngletteravatar/w.png b/src/images/kivy/ngletteravatar/w.png new file mode 100644 index 00000000..20ff7ed9 Binary files /dev/null and b/src/images/kivy/ngletteravatar/w.png differ diff --git a/src/images/kivy/ngletteravatar/x.jpg b/src/images/kivy/ngletteravatar/x.jpg new file mode 100644 index 00000000..107f1732 Binary files /dev/null and b/src/images/kivy/ngletteravatar/x.jpg differ diff --git a/src/images/kivy/ngletteravatar/z.png b/src/images/kivy/ngletteravatar/z.png new file mode 100644 index 00000000..efcda8fe Binary files /dev/null and b/src/images/kivy/ngletteravatar/z.png differ diff --git a/src/images/no_identicons.png b/src/images/kivy/no_identicons.png similarity index 100% rename from src/images/no_identicons.png rename to src/images/kivy/no_identicons.png diff --git a/src/images/btc.png b/src/images/kivy/payment/btc.png similarity index 100% rename from src/images/btc.png rename to src/images/kivy/payment/btc.png diff --git a/src/images/buy.png b/src/images/kivy/payment/buy.png similarity index 100% rename from src/images/buy.png rename to src/images/kivy/payment/buy.png diff --git a/src/images/buynew.png b/src/images/kivy/payment/buynew.png similarity index 100% rename from src/images/buynew.png rename to src/images/kivy/payment/buynew.png diff --git a/src/images/buynew1.png b/src/images/kivy/payment/buynew1.png similarity index 100% rename from src/images/buynew1.png rename to src/images/kivy/payment/buynew1.png diff --git a/src/images/credits.jpeg b/src/images/kivy/payment/credits.jpeg similarity index 100% rename from src/images/credits.jpeg rename to src/images/kivy/payment/credits.jpeg diff --git a/src/images/creditss.png b/src/images/kivy/payment/creditss.png similarity index 100% rename from src/images/creditss.png rename to src/images/kivy/payment/creditss.png diff --git a/src/images/gpay.png b/src/images/kivy/payment/gpay.png similarity index 100% rename from src/images/gpay.png rename to src/images/kivy/payment/gpay.png diff --git a/src/images/gplay.png b/src/images/kivy/payment/gplay.png similarity index 100% rename from src/images/gplay.png rename to src/images/kivy/payment/gplay.png diff --git a/src/images/gplayfinal.png b/src/images/kivy/payment/gplayfinal.png similarity index 100% rename from src/images/gplayfinal.png rename to src/images/kivy/payment/gplayfinal.png diff --git a/src/images/gplayss.png b/src/images/kivy/payment/gplayss.png similarity index 100% rename from src/images/gplayss.png rename to src/images/kivy/payment/gplayss.png diff --git a/src/images/paypal.png b/src/images/kivy/payment/paypal.png similarity index 100% rename from src/images/paypal.png rename to src/images/kivy/payment/paypal.png diff --git a/src/images/kivy/plus-4-xxl.png b/src/images/kivy/plus-4-xxl.png new file mode 100644 index 00000000..1f178267 Binary files /dev/null and b/src/images/kivy/plus-4-xxl.png differ diff --git a/src/images/kivy/plus.png b/src/images/kivy/plus.png new file mode 100644 index 00000000..4fd3478c Binary files /dev/null and b/src/images/kivy/plus.png differ diff --git a/src/images/kivy/qidenticon.png b/src/images/kivy/qidenticon.png new file mode 100644 index 00000000..21abec78 Binary files /dev/null and b/src/images/kivy/qidenticon.png differ diff --git a/src/images/kivy/qidenticon_two.png b/src/images/kivy/qidenticon_two.png new file mode 100644 index 00000000..35180659 Binary files /dev/null and b/src/images/kivy/qidenticon_two.png differ diff --git a/src/images/kivy/qidenticon_two_x.png b/src/images/kivy/qidenticon_two_x.png new file mode 100644 index 00000000..a4851205 Binary files /dev/null and b/src/images/kivy/qidenticon_two_x.png differ diff --git a/src/images/kivy/qidenticon_x.png b/src/images/kivy/qidenticon_x.png new file mode 100644 index 00000000..07e903e5 Binary files /dev/null and b/src/images/kivy/qidenticon_x.png differ diff --git a/src/images/red.png b/src/images/kivy/red.png similarity index 100% rename from src/images/red.png rename to src/images/kivy/red.png diff --git a/src/images/kivy/redicon.png b/src/images/kivy/redicon.png new file mode 100644 index 00000000..dfc84b47 Binary files /dev/null and b/src/images/kivy/redicon.png differ diff --git a/src/images/right-arrow.png b/src/images/kivy/right-arrow.png similarity index 100% rename from src/images/right-arrow.png rename to src/images/kivy/right-arrow.png diff --git a/src/images/search.png b/src/images/kivy/search.png similarity index 100% rename from src/images/search.png rename to src/images/kivy/search.png diff --git a/src/images/search_mail.png b/src/images/kivy/search_mail.png similarity index 100% rename from src/images/search_mail.png rename to src/images/kivy/search_mail.png diff --git a/src/images/kivy/send.png b/src/images/kivy/send.png new file mode 100644 index 00000000..6a7c8302 Binary files /dev/null and b/src/images/kivy/send.png differ diff --git a/src/images/kivy/sent.png b/src/images/kivy/sent.png new file mode 100644 index 00000000..01b5f0dd Binary files /dev/null and b/src/images/kivy/sent.png differ diff --git a/src/images/kivy/subscriptions.png b/src/images/kivy/subscriptions.png new file mode 100644 index 00000000..e4561208 Binary files /dev/null and b/src/images/kivy/subscriptions.png differ diff --git a/src/images/text_images/!.png b/src/images/kivy/text_images/!.png similarity index 100% rename from src/images/text_images/!.png rename to src/images/kivy/text_images/!.png diff --git a/src/images/text_images/0.png b/src/images/kivy/text_images/0.png similarity index 100% rename from src/images/text_images/0.png rename to src/images/kivy/text_images/0.png diff --git a/src/images/text_images/1.png b/src/images/kivy/text_images/1.png similarity index 100% rename from src/images/text_images/1.png rename to src/images/kivy/text_images/1.png diff --git a/src/images/text_images/2.png b/src/images/kivy/text_images/2.png similarity index 100% rename from src/images/text_images/2.png rename to src/images/kivy/text_images/2.png diff --git a/src/images/text_images/3.png b/src/images/kivy/text_images/3.png similarity index 100% rename from src/images/text_images/3.png rename to src/images/kivy/text_images/3.png diff --git a/src/images/text_images/4.png b/src/images/kivy/text_images/4.png similarity index 100% rename from src/images/text_images/4.png rename to src/images/kivy/text_images/4.png diff --git a/src/images/text_images/5.png b/src/images/kivy/text_images/5.png similarity index 100% rename from src/images/text_images/5.png rename to src/images/kivy/text_images/5.png diff --git a/src/images/text_images/6.png b/src/images/kivy/text_images/6.png similarity index 100% rename from src/images/text_images/6.png rename to src/images/kivy/text_images/6.png diff --git a/src/images/text_images/7.png b/src/images/kivy/text_images/7.png similarity index 100% rename from src/images/text_images/7.png rename to src/images/kivy/text_images/7.png diff --git a/src/images/text_images/8.png b/src/images/kivy/text_images/8.png similarity index 100% rename from src/images/text_images/8.png rename to src/images/kivy/text_images/8.png diff --git a/src/images/text_images/9.png b/src/images/kivy/text_images/9.png similarity index 100% rename from src/images/text_images/9.png rename to src/images/kivy/text_images/9.png diff --git a/src/images/text_images/A.png b/src/images/kivy/text_images/A.png similarity index 100% rename from src/images/text_images/A.png rename to src/images/kivy/text_images/A.png diff --git a/src/images/text_images/B.png b/src/images/kivy/text_images/B.png similarity index 100% rename from src/images/text_images/B.png rename to src/images/kivy/text_images/B.png diff --git a/src/images/text_images/C.png b/src/images/kivy/text_images/C.png similarity index 100% rename from src/images/text_images/C.png rename to src/images/kivy/text_images/C.png diff --git a/src/images/text_images/D.png b/src/images/kivy/text_images/D.png similarity index 100% rename from src/images/text_images/D.png rename to src/images/kivy/text_images/D.png diff --git a/src/images/text_images/E.png b/src/images/kivy/text_images/E.png similarity index 100% rename from src/images/text_images/E.png rename to src/images/kivy/text_images/E.png diff --git a/src/images/text_images/F.png b/src/images/kivy/text_images/F.png similarity index 100% rename from src/images/text_images/F.png rename to src/images/kivy/text_images/F.png diff --git a/src/images/text_images/G.png b/src/images/kivy/text_images/G.png similarity index 100% rename from src/images/text_images/G.png rename to src/images/kivy/text_images/G.png diff --git a/src/images/text_images/H.png b/src/images/kivy/text_images/H.png similarity index 100% rename from src/images/text_images/H.png rename to src/images/kivy/text_images/H.png diff --git a/src/images/text_images/I.png b/src/images/kivy/text_images/I.png similarity index 100% rename from src/images/text_images/I.png rename to src/images/kivy/text_images/I.png diff --git a/src/images/text_images/J.png b/src/images/kivy/text_images/J.png similarity index 100% rename from src/images/text_images/J.png rename to src/images/kivy/text_images/J.png diff --git a/src/images/text_images/K.png b/src/images/kivy/text_images/K.png similarity index 100% rename from src/images/text_images/K.png rename to src/images/kivy/text_images/K.png diff --git a/src/images/text_images/L.png b/src/images/kivy/text_images/L.png similarity index 100% rename from src/images/text_images/L.png rename to src/images/kivy/text_images/L.png diff --git a/src/images/text_images/M.png b/src/images/kivy/text_images/M.png similarity index 100% rename from src/images/text_images/M.png rename to src/images/kivy/text_images/M.png diff --git a/src/images/text_images/N.png b/src/images/kivy/text_images/N.png similarity index 100% rename from src/images/text_images/N.png rename to src/images/kivy/text_images/N.png diff --git a/src/images/text_images/O.png b/src/images/kivy/text_images/O.png similarity index 100% rename from src/images/text_images/O.png rename to src/images/kivy/text_images/O.png diff --git a/src/images/text_images/P.png b/src/images/kivy/text_images/P.png similarity index 100% rename from src/images/text_images/P.png rename to src/images/kivy/text_images/P.png diff --git a/src/images/text_images/Q.png b/src/images/kivy/text_images/Q.png similarity index 100% rename from src/images/text_images/Q.png rename to src/images/kivy/text_images/Q.png diff --git a/src/images/text_images/R.png b/src/images/kivy/text_images/R.png similarity index 100% rename from src/images/text_images/R.png rename to src/images/kivy/text_images/R.png diff --git a/src/images/text_images/S.png b/src/images/kivy/text_images/S.png similarity index 100% rename from src/images/text_images/S.png rename to src/images/kivy/text_images/S.png diff --git a/src/images/text_images/T.png b/src/images/kivy/text_images/T.png similarity index 100% rename from src/images/text_images/T.png rename to src/images/kivy/text_images/T.png diff --git a/src/images/text_images/U.png b/src/images/kivy/text_images/U.png similarity index 100% rename from src/images/text_images/U.png rename to src/images/kivy/text_images/U.png diff --git a/src/images/text_images/V.png b/src/images/kivy/text_images/V.png similarity index 100% rename from src/images/text_images/V.png rename to src/images/kivy/text_images/V.png diff --git a/src/images/text_images/W.png b/src/images/kivy/text_images/W.png similarity index 100% rename from src/images/text_images/W.png rename to src/images/kivy/text_images/W.png diff --git a/src/images/text_images/X.png b/src/images/kivy/text_images/X.png similarity index 100% rename from src/images/text_images/X.png rename to src/images/kivy/text_images/X.png diff --git a/src/images/text_images/Y.png b/src/images/kivy/text_images/Y.png similarity index 100% rename from src/images/text_images/Y.png rename to src/images/kivy/text_images/Y.png diff --git a/src/images/text_images/Z.png b/src/images/kivy/text_images/Z.png similarity index 100% rename from src/images/text_images/Z.png rename to src/images/kivy/text_images/Z.png diff --git a/src/images/transparent.png b/src/images/kivy/transparent.png similarity index 100% rename from src/images/transparent.png rename to src/images/kivy/transparent.png diff --git a/src/images/white.png b/src/images/kivy/white.png similarity index 100% rename from src/images/white.png rename to src/images/kivy/white.png diff --git a/src/images/kivy/yellowicon.png b/src/images/kivy/yellowicon.png new file mode 100644 index 00000000..95e451d5 Binary files /dev/null and b/src/images/kivy/yellowicon.png differ diff --git a/src/images/paymode/111.webp b/src/images/paymode/111.webp deleted file mode 100644 index 7b38349e..00000000 Binary files a/src/images/paymode/111.webp and /dev/null differ diff --git a/src/images/paymode/bitcoin-logo.jpg b/src/images/paymode/bitcoin-logo.jpg deleted file mode 100644 index a5c5bdbb..00000000 Binary files a/src/images/paymode/bitcoin-logo.jpg and /dev/null differ diff --git a/src/images/paymode/download.png b/src/images/paymode/download.png deleted file mode 100644 index 68c7f087..00000000 Binary files a/src/images/paymode/download.png and /dev/null differ diff --git a/src/state.py b/src/state.py index eeda27c1..62848c25 100644 --- a/src/state.py +++ b/src/state.py @@ -129,3 +129,5 @@ ackdataForWhichImWatching = {} thisapp = None """Singleton instance""" + +imageDir = None