Skip to content

Commit c392702

Browse files
committed
Added tip for new users
1 parent d29119b commit c392702

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

python_password/PyPassword.kv

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,10 @@
4040
IconLeftWidget:
4141
icon: 'information-outline'
4242

43+
<NewbieTip>:
44+
IconLeftWidget:
45+
icon: root.icon
46+
4347
Screen:
4448
MDToolbar:
4549
id: toolbar

python_password/PyPassword.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,14 @@
1010
from cryptography.hazmat.primitives import hashes
1111
from cryptography.hazmat.primitives.kdf.pbkdf2 import PBKDF2HMAC
1212
from kivy import Config
13-
from kivy.properties import ObjectProperty
13+
from kivy.properties import ObjectProperty, StringProperty
1414
from kivy.uix.boxlayout import BoxLayout
1515
from kivymd.app import MDApp
1616
from kivymd.uix.button import MDRectangleFlatIconButton, MDRaisedButton, MDFillRoundFlatIconButton, \
1717
MDRoundFlatIconButton
1818
from kivymd.uix.dialog import MDDialog
19-
from kivymd.uix.list import OneLineListItem
19+
from kivymd.uix.list import OneLineListItem, ThreeLineAvatarListItem, IconRightWidget, IconLeftWidget, \
20+
ThreeLineIconListItem
2021

2122
from python_password.utils.crypto import *
2223
from python_password.utils.database import *
@@ -46,6 +47,11 @@ def alert(self):
4647
return alert
4748

4849

50+
class NewbieTip(ThreeLineIconListItem):
51+
"""Widget that's showed when there's one or two passwords in database."""
52+
icon = StringProperty()
53+
54+
4955
class ContentNavigationDrawer(BoxLayout):
5056
"""Container for side menu."""
5157
screen_manager = ObjectProperty()

0 commit comments

Comments
 (0)