rename kivy_garden to qr_scanner

This commit is contained in:
cis 2021-06-15 19:36:47 +05:30
parent 41064d8929
commit baf423e116
No known key found for this signature in database
GPG Key ID: 11DC6F36E8B65B24
17 changed files with 6 additions and 9 deletions

View File

@ -2,6 +2,7 @@ import state
from bitmessagekivy.baseclass.common import toast from bitmessagekivy.baseclass.common import toast
from kivy.uix.screenmanager import Screen from kivy.uix.screenmanager import Screen
from kivy.properties import StringProperty from kivy.properties import StringProperty
from kivy_garden.qrcode import QRCodeWidget
class ShowQRCode(Screen): class ShowQRCode(Screen):
@ -12,10 +13,6 @@ class ShowQRCode(Screen):
"""Method used for showing QR Code""" """Method used for showing QR Code"""
self.ids.qr.clear_widgets() self.ids.qr.clear_widgets()
state.kivyapp.set_toolbar_for_QrCode() state.kivyapp.set_toolbar_for_QrCode()
try:
from kivy.garden.qrcode import QRCodeWidget
except Exception:
from kivy_garden.qrcode import QRCodeWidget
self.address = address self.address = address
self.ids.qr.add_widget(QRCodeWidget(data=address)) self.ids.qr.add_widget(QRCodeWidget(data=address))
self.ids.qr.children[0].show_border = False self.ids.qr.children[0].show_border = False

View File

@ -58,7 +58,7 @@ import ast
from bitmessagekivy.baseclass.common import toast from bitmessagekivy.baseclass.common import toast
from kivy_garden.zbarcam import ZBarCam from qr_scanner.zbarcam import ZBarCam
from pyzbar.pyzbar import ZBarSymbol from pyzbar.pyzbar import ZBarSymbol
if platform != "android": if platform != "android":

View File

@ -3,7 +3,7 @@ from kivy.app import App
from kivy.lang import Builder from kivy.lang import Builder
kv = """ kv = """
#:import XCamera kivy_garden.xcamera.XCamera #:import XCamera qr_scanner.xcamera.XCamera
FloatLayout: FloatLayout:
orientation: 'vertical' orientation: 'vertical'

View File

@ -1,4 +1,4 @@
#:import xcamera kivy_garden.xcamera.xcamera #:import xcamera qr_scanner.xcamera.xcamera
<XCameraIconButton> <XCameraIconButton>
icon_color: (0, 0, 0, 1) icon_color: (0, 0, 0, 1)

View File

@ -1,5 +1,5 @@
#:import XCamera kivy_garden.xcamera.XCamera #:import XCamera qr_scanner.xcamera.XCamera
#:import is_android kivy_garden.zbarcam.utils.is_android #:import is_android qr_scanner.zbarcam.utils.is_android
<ZBarCam>: <ZBarCam>:
Widget: Widget:
# invert width/height on rotated Android # invert width/height on rotated Android