android-notify 1.52.3__tar.gz → 1.52.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of android-notify might be problematic. Click here for more details.
- {android_notify-1.52.3 → android_notify-1.52.5}/PKG-INFO +15 -9
- {android_notify-1.52.3 → android_notify-1.52.5}/README.md +14 -8
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify/sword.py +137 -110
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify.egg-info/PKG-INFO +15 -9
- {android_notify-1.52.3 → android_notify-1.52.5}/setup.py +1 -1
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify/__init__.py +0 -0
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify/__main__.py +0 -0
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify/core.py +0 -0
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify/styles.py +0 -0
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify.egg-info/SOURCES.txt +0 -0
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify.egg-info/dependency_links.txt +0 -0
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify.egg-info/requires.txt +0 -0
- {android_notify-1.52.3 → android_notify-1.52.5}/android_notify.egg-info/top_level.txt +0 -0
- {android_notify-1.52.3 → android_notify-1.52.5}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.2
|
|
2
2
|
Name: android-notify
|
|
3
|
-
Version: 1.52.
|
|
3
|
+
Version: 1.52.5
|
|
4
4
|
Summary: A Python package that simpilfies creating Android notifications in Kivy apps.
|
|
5
5
|
Home-page: https://github.com/fector101/android-notify
|
|
6
6
|
Author: Fabian
|
|
@@ -128,17 +128,23 @@ The library supports multiple notification styles:
|
|
|
128
128
|
#### Progress Bar notification
|
|
129
129
|
|
|
130
130
|
```python
|
|
131
|
-
|
|
131
|
+
|
|
132
|
+
progress = 0
|
|
132
133
|
|
|
133
134
|
notification = Notification(
|
|
134
|
-
title="Downloading...",
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
progress_current_value=0
|
|
139
|
-
)
|
|
135
|
+
title="Downloading...", message="0% downloaded",
|
|
136
|
+
style= "progress",
|
|
137
|
+
progress_current_value=0,progress_max_value=100
|
|
138
|
+
)
|
|
140
139
|
notification.send()
|
|
141
|
-
|
|
140
|
+
|
|
141
|
+
def update_progress(dt):
|
|
142
|
+
global progress
|
|
143
|
+
progress = min(progress + 10, 100)
|
|
144
|
+
notification.updateProgressBar(progress, f"{progress}% downloaded")
|
|
145
|
+
return progress < 100 # Stops when reaching 100%
|
|
146
|
+
|
|
147
|
+
Clock.schedule_interval(update_progress, 3)
|
|
142
148
|
```
|
|
143
149
|
|
|
144
150
|
**Sample Image:**
|
|
@@ -92,17 +92,23 @@ The library supports multiple notification styles:
|
|
|
92
92
|
#### Progress Bar notification
|
|
93
93
|
|
|
94
94
|
```python
|
|
95
|
-
|
|
95
|
+
|
|
96
|
+
progress = 0
|
|
96
97
|
|
|
97
98
|
notification = Notification(
|
|
98
|
-
title="Downloading...",
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
progress_current_value=0
|
|
103
|
-
)
|
|
99
|
+
title="Downloading...", message="0% downloaded",
|
|
100
|
+
style= "progress",
|
|
101
|
+
progress_current_value=0,progress_max_value=100
|
|
102
|
+
)
|
|
104
103
|
notification.send()
|
|
105
|
-
|
|
104
|
+
|
|
105
|
+
def update_progress(dt):
|
|
106
|
+
global progress
|
|
107
|
+
progress = min(progress + 10, 100)
|
|
108
|
+
notification.updateProgressBar(progress, f"{progress}% downloaded")
|
|
109
|
+
return progress < 100 # Stops when reaching 100%
|
|
110
|
+
|
|
111
|
+
Clock.schedule_interval(update_progress, 3)
|
|
106
112
|
```
|
|
107
113
|
|
|
108
114
|
**Sample Image:**
|
|
@@ -4,6 +4,7 @@ import traceback
|
|
|
4
4
|
import os
|
|
5
5
|
import threading
|
|
6
6
|
import re
|
|
7
|
+
import time
|
|
7
8
|
from .styles import NotificationStyles
|
|
8
9
|
|
|
9
10
|
DEV=0
|
|
@@ -36,7 +37,7 @@ except Exception as e:# pylint: disable=W0718
|
|
|
36
37
|
def run_on_ui_thread(func):
|
|
37
38
|
"""Fallback for Developing on PC"""
|
|
38
39
|
def wrapper(*args, **kwargs):
|
|
39
|
-
print("Simulating run on UI thread")
|
|
40
|
+
# print("Simulating run on UI thread")
|
|
40
41
|
return func(*args, **kwargs)
|
|
41
42
|
return wrapper
|
|
42
43
|
|
|
@@ -143,6 +144,7 @@ class Notification:
|
|
|
143
144
|
# Private (Don't Touch)
|
|
144
145
|
self.__id = self.__getUniqueID()
|
|
145
146
|
self.__setArgs(kwargs)
|
|
147
|
+
self.__update_timer = None # To Track progressbar last update (According to Android Docs Don't update bar to often, I also faced so issues when doing that)
|
|
146
148
|
|
|
147
149
|
if not ON_ANDROID:
|
|
148
150
|
return
|
|
@@ -176,33 +178,52 @@ class Notification:
|
|
|
176
178
|
self.__builder.setContentText(String(self.message))
|
|
177
179
|
|
|
178
180
|
def updateProgressBar(self,current_value,message:str=''):
|
|
179
|
-
"""current_value is the value to set progressbar, message defaults to last message
|
|
181
|
+
"""current_value is the value to set progressbar, message defaults to last message
|
|
182
|
+
|
|
183
|
+
NOTE: There is a 0.5sec delay
|
|
184
|
+
"""
|
|
180
185
|
|
|
181
|
-
|
|
182
|
-
|
|
186
|
+
# Cancel any existing timer before setting a new one
|
|
187
|
+
if self.__update_timer:
|
|
188
|
+
return False
|
|
183
189
|
|
|
184
|
-
|
|
185
|
-
|
|
190
|
+
def delayed_update():
|
|
191
|
+
self.__update_timer = None
|
|
192
|
+
if self.logs:
|
|
193
|
+
print(f'Progress Bar Update value: {current_value}')
|
|
186
194
|
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
195
|
+
self.progress_current_value = current_value
|
|
196
|
+
|
|
197
|
+
if not ON_ANDROID:
|
|
198
|
+
return False
|
|
199
|
+
self.__builder.setProgress(self.progress_max_value, current_value, False)
|
|
200
|
+
if message:
|
|
201
|
+
self.updateMessage(message)
|
|
202
|
+
self.notification_manager.notify(self.__id, self.__builder.build())
|
|
203
|
+
return True
|
|
191
204
|
|
|
205
|
+
# Start a new timer that runs after 0.5 seconds
|
|
206
|
+
self.__update_timer = threading.Timer(0.5, delayed_update)
|
|
207
|
+
self.__update_timer.start()
|
|
208
|
+
|
|
192
209
|
def removeProgressBar(self,message=''):
|
|
193
210
|
"""message defaults to last message"""
|
|
194
211
|
|
|
212
|
+
if self.__update_timer:
|
|
213
|
+
self.__update_timer.cancel()
|
|
214
|
+
self.__update_timer = None
|
|
215
|
+
|
|
195
216
|
if self.logs:
|
|
196
217
|
print(f'removed progress bar with message: {self.message}')
|
|
197
218
|
|
|
198
219
|
if not ON_ANDROID:
|
|
199
|
-
return
|
|
220
|
+
return False
|
|
200
221
|
|
|
201
222
|
if message:
|
|
202
223
|
self.__builder.setContentText(String(message))
|
|
203
|
-
return True
|
|
204
224
|
self.__builder.setProgress(0, 0, False)
|
|
205
225
|
self.notification_manager.notify(self.__id, self.__builder.build())
|
|
226
|
+
return True
|
|
206
227
|
|
|
207
228
|
def send(self,silent:bool=False):
|
|
208
229
|
"""Sends notification
|
|
@@ -226,6 +247,101 @@ class Notification:
|
|
|
226
247
|
print(f'channel_name: {self.channel_name}, Channel ID: {self.channel_id}, id: {self.__id}')
|
|
227
248
|
print('Can\'t Send Package Only Runs on Android !!! ---> Check "https://github.com/Fector101/android_notify/" for Documentation.\n' if DEV else '\n') # pylint: disable=C0301
|
|
228
249
|
|
|
250
|
+
def addButton(self, text:str,on_release):
|
|
251
|
+
"""For adding action buttons
|
|
252
|
+
|
|
253
|
+
Args:
|
|
254
|
+
text (str): Text For Button
|
|
255
|
+
"""
|
|
256
|
+
if self.logs:
|
|
257
|
+
print('Added Button: ', text)
|
|
258
|
+
|
|
259
|
+
if not ON_ANDROID:
|
|
260
|
+
return
|
|
261
|
+
|
|
262
|
+
btn_id= self.__getIDForButton()
|
|
263
|
+
action = f"BTN_ACTION_{btn_id}"
|
|
264
|
+
|
|
265
|
+
action_intent = Intent(context, PythonActivity)
|
|
266
|
+
action_intent.setAction(action)
|
|
267
|
+
action_intent.setFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP)
|
|
268
|
+
bundle = Bundle()
|
|
269
|
+
bundle.putString("title", self.title or 'Title Placeholder')
|
|
270
|
+
bundle.putInt("key_int", 123)
|
|
271
|
+
action_intent.putExtras(bundle)
|
|
272
|
+
action_intent.putExtra("button_id", btn_id)
|
|
273
|
+
|
|
274
|
+
self.btns_box[action] = on_release
|
|
275
|
+
# action_intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP)
|
|
276
|
+
|
|
277
|
+
if self.logs:
|
|
278
|
+
print('Button id: ',btn_id)
|
|
279
|
+
pending_action_intent = PendingIntent.getActivity(
|
|
280
|
+
context,
|
|
281
|
+
0,
|
|
282
|
+
action_intent,
|
|
283
|
+
PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_IMMUTABLE
|
|
284
|
+
)
|
|
285
|
+
# Convert text to CharSequence
|
|
286
|
+
action_text = cast('java.lang.CharSequence', String(text))
|
|
287
|
+
|
|
288
|
+
|
|
289
|
+
|
|
290
|
+
# Add action with proper types
|
|
291
|
+
self.__builder.addAction(
|
|
292
|
+
int(context.getApplicationInfo().icon), # Cast icon to int
|
|
293
|
+
action_text, # CharSequence text
|
|
294
|
+
pending_action_intent # PendingIntent
|
|
295
|
+
)
|
|
296
|
+
# Set content intent for notification tap
|
|
297
|
+
self.__builder.setContentIntent(pending_action_intent)
|
|
298
|
+
|
|
299
|
+
@run_on_ui_thread
|
|
300
|
+
def addNotificationStyle(self,style:str,already_sent=False):
|
|
301
|
+
"""Adds Style to Notification
|
|
302
|
+
Version 1.51.2+ Exposes method to Users (Note): Always try to Call On UI Thread
|
|
303
|
+
|
|
304
|
+
Args:
|
|
305
|
+
style (str): required style
|
|
306
|
+
"""
|
|
307
|
+
|
|
308
|
+
if not ON_ANDROID:
|
|
309
|
+
# TODO for logs when not on android and style related to imgs etraxct app path from buildozer.spec and print
|
|
310
|
+
return False
|
|
311
|
+
|
|
312
|
+
if style == NotificationStyles.BIG_TEXT:
|
|
313
|
+
big_text_style = NotificationCompatBigTextStyle() # pylint: disable=E0606
|
|
314
|
+
big_text_style.bigText(str(self.body))
|
|
315
|
+
self.__builder.setStyle(big_text_style)
|
|
316
|
+
|
|
317
|
+
elif style == NotificationStyles.INBOX:
|
|
318
|
+
inbox_style = NotificationCompatInboxStyle() # pylint: disable=E0606
|
|
319
|
+
for line in self.message.split("\n"):
|
|
320
|
+
inbox_style.addLine(str(line))
|
|
321
|
+
self.__builder.setStyle(inbox_style)
|
|
322
|
+
|
|
323
|
+
elif (style == NotificationStyles.LARGE_ICON and self.large_icon_path) or (style == NotificationStyles.BIG_PICTURE and self.big_picture_path):
|
|
324
|
+
img = self.large_icon_path if style == NotificationStyles.LARGE_ICON else self.big_picture_path
|
|
325
|
+
self.__buildImg(img, style)
|
|
326
|
+
|
|
327
|
+
elif style == NotificationStyles.BOTH_IMGS and (self.big_picture_path or self.large_icon_path):
|
|
328
|
+
if self.big_picture_path:
|
|
329
|
+
self.__buildImg(self.big_picture_path, NotificationStyles.BIG_PICTURE)
|
|
330
|
+
if self.large_icon_path:
|
|
331
|
+
self.__buildImg(self.large_icon_path, NotificationStyles.LARGE_ICON)
|
|
332
|
+
|
|
333
|
+
elif style == NotificationStyles.PROGRESS:
|
|
334
|
+
self.__builder.setContentTitle(String(self.title))
|
|
335
|
+
self.__builder.setContentText(String(self.message))
|
|
336
|
+
self.__builder.setProgress(self.progress_max_value, self.progress_current_value, False)
|
|
337
|
+
|
|
338
|
+
if already_sent:
|
|
339
|
+
self.notification_manager.notify(self.__id, self.__builder.build())
|
|
340
|
+
|
|
341
|
+
return True
|
|
342
|
+
# elif style == 'custom':
|
|
343
|
+
# self.__builder = self.__doCustomStyle()
|
|
344
|
+
|
|
229
345
|
def __validateArgs(self,inputted_kwargs):
|
|
230
346
|
|
|
231
347
|
def checkInReference(inputted_keywords,accepteable_inputs,input_type):
|
|
@@ -297,51 +413,7 @@ class Notification:
|
|
|
297
413
|
self.__builder.setPriority(NotificationCompat.PRIORITY_DEFAULT if self.silent else NotificationCompat.PRIORITY_HIGH)
|
|
298
414
|
self.__builder.setOnlyAlertOnce(True)
|
|
299
415
|
self.__addIntentToOpenApp()
|
|
300
|
-
|
|
301
|
-
def addNotificationStyle(self,style:str,already_sent=False):
|
|
302
|
-
"""Adds Style to Notification
|
|
303
|
-
Version 1.51.2+ Exposes method to Users (Note): Always try to Call On UI Thread
|
|
304
|
-
|
|
305
|
-
Args:
|
|
306
|
-
style (str): required style
|
|
307
|
-
"""
|
|
308
|
-
|
|
309
|
-
if not ON_ANDROID:
|
|
310
|
-
# TODO for logs when not on android and style related to imgs etraxct app path from buildozer.spec and print
|
|
311
|
-
return
|
|
312
|
-
|
|
313
|
-
if style == NotificationStyles.BIG_TEXT:
|
|
314
|
-
big_text_style = NotificationCompatBigTextStyle() # pylint: disable=E0606
|
|
315
|
-
big_text_style.bigText(str(self.body))
|
|
316
|
-
self.__builder.setStyle(big_text_style)
|
|
317
|
-
|
|
318
|
-
elif style == NotificationStyles.INBOX:
|
|
319
|
-
inbox_style = NotificationCompatInboxStyle() # pylint: disable=E0606
|
|
320
|
-
for line in self.message.split("\n"):
|
|
321
|
-
inbox_style.addLine(str(line))
|
|
322
|
-
self.__builder.setStyle(inbox_style)
|
|
323
|
-
|
|
324
|
-
elif (style == NotificationStyles.LARGE_ICON and self.large_icon_path) or (style == NotificationStyles.BIG_PICTURE and self.big_picture_path):
|
|
325
|
-
img = self.large_icon_path if style == NotificationStyles.LARGE_ICON else self.big_picture_path
|
|
326
|
-
self.__buildImg(img, style)
|
|
327
|
-
|
|
328
|
-
elif style == NotificationStyles.BOTH_IMGS and (self.big_picture_path or self.large_icon_path):
|
|
329
|
-
if self.big_picture_path:
|
|
330
|
-
self.__buildImg(self.big_picture_path, NotificationStyles.BIG_PICTURE)
|
|
331
|
-
if self.large_icon_path:
|
|
332
|
-
self.__buildImg(self.large_icon_path, NotificationStyles.LARGE_ICON)
|
|
333
|
-
|
|
334
|
-
elif style == NotificationStyles.PROGRESS:
|
|
335
|
-
self.__builder.setContentTitle(String(self.title))
|
|
336
|
-
self.__builder.setContentText(String(self.message))
|
|
337
|
-
self.__builder.setProgress(self.progress_max_value, self.progress_current_value, False)
|
|
338
|
-
|
|
339
|
-
if already_sent:
|
|
340
|
-
self.notification_manager.notify(self.__id, self.__builder.build())
|
|
341
|
-
|
|
342
|
-
# elif style == 'custom':
|
|
343
|
-
# self.__builder = self.__doCustomStyle()
|
|
344
|
-
|
|
416
|
+
|
|
345
417
|
# def __doCustomStyle(self):
|
|
346
418
|
# # TODO Will implement when needed
|
|
347
419
|
# return self.__builder
|
|
@@ -372,7 +444,8 @@ class Notification:
|
|
|
372
444
|
return BitmapFactory.decodeStream(context.getContentResolver().openInputStream(uri))
|
|
373
445
|
|
|
374
446
|
def __getImgFromURL(self,url,img_style):
|
|
375
|
-
|
|
447
|
+
if self.logs:
|
|
448
|
+
print("getting image from URL---")
|
|
376
449
|
try:
|
|
377
450
|
URL = autoclass('java.net.URL')
|
|
378
451
|
url = URL(url)
|
|
@@ -389,7 +462,8 @@ class Notification:
|
|
|
389
462
|
|
|
390
463
|
@run_on_ui_thread
|
|
391
464
|
def __applyNotificationImage(self,bitmap,img_style):
|
|
392
|
-
|
|
465
|
+
if self.logs:
|
|
466
|
+
print('appying notification image-------')
|
|
393
467
|
try:
|
|
394
468
|
if img_style == NotificationStyles.BIG_PICTURE:
|
|
395
469
|
big_picture_style = NotificationCompatBigPictureStyle().bigPicture(bitmap) # pylint: disable=E0606
|
|
@@ -397,9 +471,11 @@ class Notification:
|
|
|
397
471
|
elif img_style == NotificationStyles.LARGE_ICON:
|
|
398
472
|
self.__builder.setLargeIcon(bitmap)
|
|
399
473
|
self.notification_manager.notify(self.__id, self.__builder.build())
|
|
400
|
-
|
|
474
|
+
if self.logs:
|
|
475
|
+
print('Done adding image to notification-------')
|
|
401
476
|
except Exception as e:
|
|
402
|
-
|
|
477
|
+
img = self.large_icon_path if img_style == NotificationStyles.LARGE_ICON else self.big_picture_path
|
|
478
|
+
print(f'Failed adding Image of style: {img_style} || From path: {img}, Exception {e}')
|
|
403
479
|
print('could stop get Img from URL ',traceback.format_exc())
|
|
404
480
|
|
|
405
481
|
def __getUniqueID(self):
|
|
@@ -464,55 +540,6 @@ class Notification:
|
|
|
464
540
|
self.button_ids.append(btn_id)
|
|
465
541
|
return btn_id
|
|
466
542
|
|
|
467
|
-
def addButton(self, text:str,on_release):
|
|
468
|
-
"""For adding action buttons
|
|
469
|
-
|
|
470
|
-
Args:
|
|
471
|
-
text (str): Text For Button
|
|
472
|
-
"""
|
|
473
|
-
if self.logs:
|
|
474
|
-
print('Added Button: ', text)
|
|
475
|
-
|
|
476
|
-
if not ON_ANDROID:
|
|
477
|
-
return
|
|
478
|
-
|
|
479
|
-
btn_id= self.__getIDForButton()
|
|
480
|
-
action = f"BTN_ACTION_{btn_id}"
|
|
481
|
-
|
|
482
|
-
action_intent = Intent(context, PythonActivity)
|
|
483
|
-
action_intent.setAction(action)
|
|
484
|
-
action_intent.setFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP)
|
|
485
|
-
bundle = Bundle()
|
|
486
|
-
bundle.putString("title", self.title or 'Title Placeholder')
|
|
487
|
-
bundle.putInt("key_int", 123)
|
|
488
|
-
action_intent.putExtras(bundle)
|
|
489
|
-
action_intent.putExtra("button_id", btn_id)
|
|
490
|
-
|
|
491
|
-
self.btns_box[action] = on_release
|
|
492
|
-
# action_intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP)
|
|
493
|
-
|
|
494
|
-
if self.logs:
|
|
495
|
-
print('Button id: ',btn_id)
|
|
496
|
-
pending_action_intent = PendingIntent.getActivity(
|
|
497
|
-
context,
|
|
498
|
-
0,
|
|
499
|
-
action_intent,
|
|
500
|
-
PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_IMMUTABLE
|
|
501
|
-
)
|
|
502
|
-
# Convert text to CharSequence
|
|
503
|
-
action_text = cast('java.lang.CharSequence', String(text))
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
# Add action with proper types
|
|
508
|
-
self.__builder.addAction(
|
|
509
|
-
int(context.getApplicationInfo().icon), # Cast icon to int
|
|
510
|
-
action_text, # CharSequence text
|
|
511
|
-
pending_action_intent # PendingIntent
|
|
512
|
-
)
|
|
513
|
-
# Set content intent for notification tap
|
|
514
|
-
self.__builder.setContentIntent(pending_action_intent)
|
|
515
|
-
|
|
516
543
|
|
|
517
544
|
class NotificationHandler:
|
|
518
545
|
"""For Notification Operations """
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.2
|
|
2
2
|
Name: android-notify
|
|
3
|
-
Version: 1.52.
|
|
3
|
+
Version: 1.52.5
|
|
4
4
|
Summary: A Python package that simpilfies creating Android notifications in Kivy apps.
|
|
5
5
|
Home-page: https://github.com/fector101/android-notify
|
|
6
6
|
Author: Fabian
|
|
@@ -128,17 +128,23 @@ The library supports multiple notification styles:
|
|
|
128
128
|
#### Progress Bar notification
|
|
129
129
|
|
|
130
130
|
```python
|
|
131
|
-
|
|
131
|
+
|
|
132
|
+
progress = 0
|
|
132
133
|
|
|
133
134
|
notification = Notification(
|
|
134
|
-
title="Downloading...",
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
progress_current_value=0
|
|
139
|
-
)
|
|
135
|
+
title="Downloading...", message="0% downloaded",
|
|
136
|
+
style= "progress",
|
|
137
|
+
progress_current_value=0,progress_max_value=100
|
|
138
|
+
)
|
|
140
139
|
notification.send()
|
|
141
|
-
|
|
140
|
+
|
|
141
|
+
def update_progress(dt):
|
|
142
|
+
global progress
|
|
143
|
+
progress = min(progress + 10, 100)
|
|
144
|
+
notification.updateProgressBar(progress, f"{progress}% downloaded")
|
|
145
|
+
return progress < 100 # Stops when reaching 100%
|
|
146
|
+
|
|
147
|
+
Clock.schedule_interval(update_progress, 3)
|
|
142
148
|
```
|
|
143
149
|
|
|
144
150
|
**Sample Image:**
|
|
@@ -6,7 +6,7 @@ with open("README.md", "r", encoding="utf-8") as readme_data:
|
|
|
6
6
|
|
|
7
7
|
setup(
|
|
8
8
|
name="android-notify",
|
|
9
|
-
version="1.52.
|
|
9
|
+
version="1.52.5",
|
|
10
10
|
author="Fabian",
|
|
11
11
|
author_email='fector101@yahoo.com',
|
|
12
12
|
description="A Python package that simpilfies creating Android notifications in Kivy apps.",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{android_notify-1.52.3 → android_notify-1.52.5}/android_notify.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|