Skining Dialogs Help

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
ekim232 Offline
Posting Freak
Posts: 1,205
Joined: Nov 2008
Reputation: 5
Location: Chicago, IL
Post: #1
Does anyone have any good tricks to skin dialogs. For the vast majority of them I have to go into a certain windows and go through several clicks and windows just to skin what is usually a easy panel or list.

Can dialogs be launch through keymap commands.

ie. <F10>xbmc.activatewindow(dialogyesno.xml)</F10>

I would love ths feature because I could sit on a window and quickly launch any dialog to see what changes I need to make and not have to go through the motions of having xbmc launch the dialog through day to day use.

I think anyone who has made a skin can agree that a project can quickly become boring when it comes time to do the dialogs. Just wanted to see if anyone had any good suggestions. Thanks.
find quote
el_Paraguayo Offline
Donor
Posts: 568
Joined: Feb 2011
Reputation: 13
Location: London, UK
Post: #2
Other than navigating to a particular window where you know the dialog would be invoked, I'd be inclined to knock up a small script that triggers the necessary dialog (e.g. YesNo, DiaolgProgress etc), and map it to a key.

That's just me, and I've been known to over-engineer solutions before!

MythSuspendAlarm: Suspend xbmc and set ACPI wake alarm based on next scheduled MythTV recording.
BBC Football Scores: Get live football score notifications.
Random Movie Script: Play random movies from user's library (for skinners).
find quote
ekim232 Offline
Posting Freak
Posts: 1,205
Joined: Nov 2008
Reputation: 5
Location: Chicago, IL
Post: #3
Does anyone know if it possible to just create a button on home.xml to trigger whatever dialog you want.

ie. <onclick>activatewindow(diaglogyesno.xml)</onclick>

I am not sure if all diaglogs can be launch from anywhere in the skin or if they must be done from a certain window.
find quote
pecinko Offline
Donor
Posts: 3,668
Joined: Dec 2008
Reputation: 48
Location: Prague / Belgrade
Post: #4
ekim232 Wrote:Does anyone know if it possible to just create a button on home.xml to trigger whatever dialog you want.

ie. <onclick>activatewindow(diaglogyesno.xml)</onclick>

I am not sure if all diaglogs can be launch from anywhere in the skin or if they must be done from a certain window.

Some of them yes. Most of them, unfortunately, no.

Don't remember which of them does open and which are problematic ones, sorry. If it helps, those that can activate are mappable in keymap.

My skins:

Amber
Quartz

(This post was last modified: 2012-03-08 19:15 by pecinko.)
find quote
Hitcher Offline
Skilled Skinner
Posts: 10,257
Joined: Aug 2007
Reputation: 80
Location: Eastleigh, UK
Post: #5
Just stick it your keymap.xml.

PHP Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<keymap>
    <global>
        <keyboard>
            <f1>ActivateWindow(virtualkeyboard)</f1>
            <F3>XBMC.UpdateLibrary(Video)</F3>
            <F4>XBMC.UpdateLibrary(Music)</F4>
            <F5>XBMC.ReloadSkin()</F5>
            <F6>Skin.ToggleSetting(DebugGrid)</F6>
            <F7>Skin.ToggleSetting(HideDebugInfo)</F7>
            <F8>Notification(Testing 123,Hello world)</F8>
        </keyboard>
    </global>
</keymap> 

Although you wont see a lot of the default labels or content.
(This post was last modified: 2012-03-09 21:25 by Hitcher.)
find quote
el_Paraguayo Offline
Donor
Posts: 568
Joined: Feb 2011
Reputation: 13
Location: London, UK
Post: #6
Hitcher,

I agree, those are esential shortcuts for those of us who like to mod skins. Nod

However, there's no shortcut to the other Dialogs, e.g. YesNo that Ekim was asking about.

I'm not aware of a quick way to trigger those dialogs, hence my comment about using a script to call them.

el_P

MythSuspendAlarm: Suspend xbmc and set ACPI wake alarm based on next scheduled MythTV recording.
BBC Football Scores: Get live football score notifications.
Random Movie Script: Play random movies from user's library (for skinners).
find quote
Hitcher Offline
Skilled Skinner
Posts: 10,257
Joined: Aug 2007
Reputation: 80
Location: Eastleigh, UK
Post: #7
Just use <f1>ActivateWindow(yesnodialog)</f1>
find quote
Balinus Offline
Skilled Skinner
Posts: 1,118
Joined: Jul 2011
Reputation: 19
Location: Montréal
Post: #8
Hitcher Wrote:Just stick it your keymap.xml.

PHP Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<keymap>
    <global>
        <keyboard>
            <f1>ActivateWindow(virtualkeyboard)</f1>
            <F3>XBMC.UpdateLibrary(Video)</F3>
            <F4>XBMC.UpdateLibrary(Music)</F4>
            <F5>XBMC.ReloadSkin()</F5>
            <F6>Skin.ToggleSetting(DebugGrid)</F6>
            <F7>Skin.ToggleSetting(HideDebugInfo)</F7>
            <F8>Notification(Testing 123,Hello world)</F8>
        </keyboard>
</keymap> 

Although you wont see a lot of the default labels or content.

There's a </global> missing I think ?
find quote
Hitcher Offline
Skilled Skinner
Posts: 10,257
Joined: Aug 2007
Reputation: 80
Location: Eastleigh, UK
Post: #9
Opps, fixed.
find quote
ekim232 Offline
Posting Freak
Posts: 1,205
Joined: Nov 2008
Reputation: 5
Location: Chicago, IL
Post: #10
Hitcher Wrote:Just use <f1>ActivateWindow(yesnodialog)</f1>

How many dialogs do you think this action can cover? How many can be launched from the home menu? That was my whole dream was to just sit in the home screen and launch dialogs so I could quickly tweak them. I do use your same keymap, and it was great day for me when you posted that awhile back for the skin.reload feature.
find quote
Hitcher Offline
Skilled Skinner
Posts: 10,257
Joined: Aug 2007
Reputation: 80
Location: Eastleigh, UK
Post: #11
Just try them and see. You'll probably have to remove the default IDs and enter some text in most things though.
find quote
el_Paraguayo Offline
Donor
Posts: 568
Joined: Feb 2011
Reputation: 13
Location: London, UK
Post: #12
Hitcher Wrote:Just try them and see. You'll probably have to remove the default IDs and enter some text in most things though.

Ah, this is what I meant. I wasn't sure how the activatewindow command generate text fire the dialogs. Never thought about hard-coding some.

Told you I always missed obvious solutions!

Thanks Hitcher.

MythSuspendAlarm: Suspend xbmc and set ACPI wake alarm based on next scheduled MythTV recording.
BBC Football Scores: Get live football score notifications.
Random Movie Script: Play random movies from user's library (for skinners).
find quote