Get rid of the time in the notification

NeoTechni

Well-Known Member
Licensed User
Longtime User
The LCARS UI notification on the left side has a time on the right side (5:03 PM)
How do I get rid of it? It's wasting space and is of little use
Not only that, but I use 24 HR time, and it's 12 HR time, so it clashes

MAGInstructions.png
 

barx

Well-Known Member
Licensed User
Longtime User
Without testing I cannot remember 100% if this is possible without a custom layout. If it were possible it would be with the Advanced Notification Library and changing the property.

B4X:
notification.When

This is what tells the system what timestamp to give the notification. Try setting it to 0 or maybe even -1.

If that fails then I think you looking at a custom layout notification.
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
Scrap that, it looks like I haven't added .when to the Advanced Notification library lol. oops

Not looked at it for a good while.

Sorry
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
I have found the source on another hard drive and after adding the required method I now get a NoClassDef error when the test app loads. I think this may be due to me only having java 1.7 and sdk17 installed on the system. The original notification that b4a currently uses is now deprecated in sdk 17.
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
OK, I added the .When method and tested on a device running ICS. Didn't make a different. Sorry
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
I think I have figured this one out. Need to do a little more testing. And also finish the library I'm currently working on. Just thought I'd post as I'm 90% convinced it works :cool:
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
The 10% may have let me down now,

For some reason, this evening I can not get it to work, even though I haven't touched that section of code. I have also tried commenting out everything in the library so that it is back to how I believe it was this morning. Yet no joy.

Will keep trying, really boggling me this is.

The annoying bit it is I still have the test app on a device that shows no time. Just sat there teasing me.
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
I managed to get the app off my other device, I have decompiled it and looked at the code, and to be honest I cannot see what is causing the issue.

I also tried updating the lib with just the code from the older version but get errors that I cannot seem to iron out.

Brain is fried. Here are the older (No time) and a newer (time) test app. If anyone wishes to try and spot what is making the time show now, feel free.

This is a real shame, I really thought I had cracked it. The fix was to simply NOT set notification.when. but now even when I remove the .when code, it still shows time. :sign0161: bad times.

View attachment nbtest_notime.apk
View attachment bntest_Time.apk
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
Well I have tried every combination possible in the code. All that is left to try is to create a new library project and re-write it again. I don't know if projects can get corrupt or anything but a couple of other bits aren't working either. And they should. So I'm going to try a re-write. See what happens.

Will keep you updated.
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
We are back on!
 
Upvote 0

NeoTechni

Well-Known Member
Licensed User
Longtime User
I suggest abandoning it and just making a library for the new extended notification system if you're starting over
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
that is what i'm doing.

Hence the requirement of waiting for me to finish the new lib

It's part of the Notification Builder lib I'm making.
 
Upvote 0

barx

Well-Known Member
Licensed User
Longtime User
Working on it. I'm thinking of releasing the basic library as version 1 very soon. Then actually working on the expanding stuff and multiple actions for a version 2. Already got most the basics working like the new numbering, progress bars, sub text, chronometer. And hiding the time. :)
 
Upvote 0
Top