xbmc python dialog without any button
#1
I would like to programm a xbmc script function that only shows txt "please wait ...."
This window or dialog should not contain any button. Is this possible ?
With the dialog xbmc function allways a button is inside
Or even better has someone a code snippet ?

regards from switzerland
Hans
Reply
#2
dialog progress doesn't sweets you?
it a better way to have a cancel button no ?

you can also update it to pass info to the user waiting in front of the dialog.
Reply
#3
ppic Wrote:dialog progress doesn't sweets you?
it a better way to have a cancel button no ?

you can also update it to pass info to the user waiting in front of the dialog.

Sorry , I allready use a progressbar during a long copy inside the script ... just a little dialog or window "please wait"

- No kind of a Button
- If it would be possible to clean the progress bar from the cancel button ... this would be fine ...

I guess this is not possible with xbmc python ....

Or is it possible to load image (a little clock) as example and after a defined time
the image go away .....

If I would like to sleep inside a script for 10 Secounds this should only signal that the
script is running ....

The python code is easy to code with sleep but as long I do sleep without any dialog-open it could seems the script is not handling correctly ...


I hope someone could help
Regards
Hans
Reply
#4
you can clean the progress bar by uodating it, and just write "please wait..."
Reply
#5
ppic Wrote:you can clean the progress bar by uodating it, and just write "please wait..."

Thanks ... this would work but there is still this cancel -button in the dialog ...

Is there may way to overpaint the button .... ?

Regards Hans

If you would press the button nothing would happen ....
Reply
#6
you can handle it:
Code:
if ( DIALOG_PROGRESS.iscanceled() ): break
place a code to relaunch your dialog progress, and the script will continue, just a hack but should work.
Reply
#7
ppic Wrote:you can handle it:
Code:
if ( DIALOG_PROGRESS.iscanceled() ): break
place a code to relaunch your dialog progress, and the script will continue, just a hack but should work.

Thank you

I wonna try to implement a own busy-dialog.
I guess this would be a nice feature enhancement for xbmc if you could
do the following

xbmc.busy(5)
sleep(5)

And during 5 secounds would be a animated gif on the screen.

Regards
Hans
Reply
#8
you can also lock the gui if you want .
Reply
#9
linuxluemmel Wrote:xbmc.busy(5)
sleep(5)

you can use busydialod in integrate in skin

PHP Code:
xbmc.executebuiltin"ActivateWindow(busydialog)" )
                
sleep)
                
xbmc.executebuiltin"Dialog.Close(busydialog)" 


cheers

frost
For my bad English, sorry. I am French Canadian.
Admin @ Passion-XBMC.org
Reply
#10
FrostBox Wrote:you can use busydialod in integrate in skin

PHP Code:
xbmc.executebuiltin"ActivateWindow(busydialog)" )
                
sleep)
                
xbmc.executebuiltin"Dialog.Close(busydialog)" 


cheers

frost

Hallo frost

You are my Hero ....

Thanks ... this was exactly what I searched ....

Merci mon vieux de canada ;-)

Hans
Reply
#11
FrostBox Wrote:you can use busydialod in integrate in skin

PHP Code:
xbmc.executebuiltin"ActivateWindow(busydialog)" )
                
sleep)
                
xbmc.executebuiltin"Dialog.Close(busydialog)" 


cheers

frost

Sorry ... I have written a little script ... no dialog comes to the front ...
Could it be that the default skin Confluence doesn't have this dialog ?

Code:
[CODE]
#!/usr/bin/python
# -*- coding: utf-8 -*-

####################### IMPORTS #######################

import xbmc, xbmcgui
import os, sys, thread, stat, time, string, re

#######################################################

#######################################################
####################### MAIN ##########################
#######################################################
if __name__ == '__main__':
     dvd = 0

     xbmc.executebuiltin("ActivateWindow(busydialog)")
     dvd = xbmc.getDVDState()
     time.sleep(15)
     xbmc.executebuiltin("Dialog.Close(busydialog)")  

     print "DVD-State value : " + str(dvd)    

#######################################################

[/CODE]


After the execution I had this inside the log .......


:03:01 T:2915359600 M:1692446720 NOTICE: -->Python Interpreter Initialized<--
16:03:01 T:3023939456 M:1692291072 ERROR: Window Translator: Can't find window busydialog
16:03:01 T:3023939456 M:1692291072 ERROR: Activate/ReplaceWindow called with invalid destination window: busydialog
16:03:06 T:3023939456 M:1693245440 ERROR: XLCDproc::Initialize - Unable to connect to host. Retry in 16 seconds.
16:03:16 T:2915359600 M:1693212672 NOTICE: DVD-State value : 3
16:03:16 T:3023939456 M:1693212672 ERROR: Window Translator: Can't find window busydialog
16:03:22 T:3023939456 M:1693016064 ERROR: XLCDproc::Initialize - Unable to connect to host. Retry in 32 seconds.

So it seems that busydialog is not valid inside Confluence ....
Reply
#12
you're butchering the logs, but i'm fairly certain your build is outdated.
Reply
#13
spiff Wrote:you're butchering the logs, but i'm fairly certain your build is outdated.

Yes , you are right ....

http://trac.xbmc.org/ticket/8733

Sorry ....
Hans
Reply
#14
hi linuxluemmel,

I tested your code with 2 builds and confluence, work great

PHP Code:
import xbmctime
    dvd 
0
    
print "ActivateWindow(busydialog)"
    
xbmc.executebuiltin("ActivateWindow(busydialog)")
    
dvd xbmc.getDVDState() 
    
time.sleep(15)
    
xbmc.executebuiltin("Dialog.Close(busydialog)")  
    print 
"Dialog.Close(busydialog)"
    
print "DVD-State value : " str(dvd
with r31123:
Code:
11:06:02 T:3384 M:294461440  NOTICE: ActivateWindow(busydialog)
11:06:18 T:3384 M:294252544  NOTICE: Dialog.Close(busydialog)
11:06:18 T:3384 M:294252544  NOTICE: DVD-State value : 3
with r28256:
Image

Image
For my bad English, sorry. I am French Canadian.
Admin @ Passion-XBMC.org
Reply
#15
FrostBox Wrote:hi linuxluemmel,
I tested your code with 2 builds and confluence, work great

Now I know ... In next coming release it will be shown ... thanks

I saw that the xbmc function did return value 3 .....
Did you insert a dvd ?
I can do what I want ... the python code allways have a return value 3 ...-(

this would be the same problem I have

http://forum.xbmc.org/showthread.php?tid=75584

Regards
Hans
Reply

Logout Mark Read Team Forum Stats Members Help
xbmc python dialog without any button0