Shortcut creating bookmarks?
#16
Argh, sorry, my mistake. The keyboard.xml should look like this:
Code:
<keymap>
  <FullscreenVideo>
    <keyboard>
      <b>ActivateWindow(VideoBookmarks)</b>
    </keyboard>
  </FullscreenVideo>
  <VideoOSD>
    <keyboard>
      <b>ActivateWindow(VideoBookmarks)</b>
    </keyboard>
  </VideoOSD>
</keymap>

Make similar corrections to your zepo version of this file.
Reply
#17
Great, your keyboard.xml works now, artrafael. The bookmark windows opens.

Zepo's doesn't yet...no, it works, by pressing "b" a bookmark is created without showing the bookmarks window, there is just created a bookmark.

The navigation through the file lists with "Home", "Page down" etc.does not work, yet.

Zepo's keyboard.xml now:

Code:
<keymap>
  <FullscreenVideo>
    <keyboard>
      <b>RunScript(C:\Users\Dirk\AppData\Roaming\XBMC\userdata\setbookmark.py)</b>
    </keyboard>
  </FullscreenVideo>
  <VideoOSD>
    <keyboard>
      <b>RunScript(C:\Users\Dirk\AppData\Roaming\XBMC\userdata\setbookmark.py)</b>
    </keyboard>
  </VideoOSD>
</keymap>

Reply
#18
(2013-01-23, 20:47)Dirki Wrote: Zepo's doesn't yet...no, it works, by pressing "b" a bookmark is created without showing the bookmarks window, there is just created a bookmark.

If it does create a bookmark, then it's working as designed. What more did you expect it to do?

Quote:The navigation through the file lists with "Home", "Page down" etc.does not work, yet.

The keyboard.xml samples we've so far provided you have nothing to do with these keys. These should be working for you out-of-the-box since they are defined in the installation (default) keyboard.xml file. Have you verified the Home/End and PgUp/PgDn keys work outside of XBMC? If they behave correctly outside of XBMC, then check your debug log (wiki) as explained previously to see what happens under-the-covers when you press these keys in XBMC. If those keys don't work as expected outside of XBMC either, then you may have chosen the wrong keyboard layout for your system.

Reply
#19
Quote:If it does create a bookmark, then it's working as designed. What more did you expect it to do?
Exactly that, that's it, many thanks.

Quote:The keyboard.xml samples we've so far provided you have nothing to do with these keys. These should be working for you out-of-the-box since they are defined in the installation (default) keyboard.xml file.
In this file the key "Home" seems to be used three times, but not for a file list, if I see right.

Quote:Have you verified the Home/End and PgUp/PgDn keys work outside of XBMC?
Yes, I often use these keys.

Here is the log: http://xbmclogs.com/show.php?id=29893
Reply
#20
It looks like you are using the Home/End, PgUp/PgDn keys on your numeric pad. Instead, use the dedicated keys for these functions located to the left of the numeric pad.
Reply
#21
Quote:It looks like you are using the Home/End, PgUp/PgDn keys on your numeric pad.
Yes, I do.

Quote: Instead, use the dedicated keys for these functions located to the left of the numeric pad.
Sorry, I cannot find these keys a second time on my keyboard.
Reply
#22
What make/model keyboard are you using? Do you have a link to a photo of the keyboard layout?
Reply
#23
I use a Notebook, I assume the image will not be big enough: http://www.aldi.medion.com/md98310/nord_01/
or a little bit bigger, but the perspective...
http://i.computer-bild.de/imgs/3/2/2/9/2...131d1e.jpg

Can I combine the code of zepo and your's, so e.g. pressing "b" creates a bookmark and pressing CRTL + b shows the bookmark window?
And when pressing "b" could there be something like a confirmation sound / window, so I know the bookmark is really created?
Reply
#24
It doesn't appear your notebook keyboard has dedicated buttons for Home/End and PgUp/PgDn (the photos are small and I can't read the German(?) labels on the keytops). The problem is that toggling the NumLock doesn't change the key presses on the numeric pad as far as XBMC is concerned. For example, pressing the number 7 on the keypad sends numpadseven, regardless of whether or not NumLock is enabled.

You can map other keys to perform the desired actions. One option is to remap the numeric pad 1, 3, 7, and 9 keys to perform the actions of the "real" End, PgDn, Home, and PgUp keys respectively. However, if you do this, this will mean you won't be able to use the numpad to enter the numbers 1, 3, 7, and 9 in XBMC; instead, you will have to use the number keys on the top row of the main section of your keyboard to type numbers. An alternative is to assign these actions to some other unused keys, such as F1-F12.

Insert the following lines (from <global> to </global>, inclusive) into the keyboard.xml file you had previously created:
Code:
<keymap>
  <global>
    <keyboard>
      <numpadone>LastPage</numpadone>
      <numpadthree>PageDown</numpadthree>
      <numpadseven>FirstPage</numpadseven>
      <numpadnine>PageUp</numpadnine>
    </keyboard>
  </global>
   :
   :  (Your previous statements)
   :
</keymap>
This example remaps some of the numeric pad numbers to these actions. Change accordingly if you prefer to use some of the F1-F12 keys or some others.

Quote:Can I combine the code of zepo and your's, so e.g. pressing "b" creates a bookmark and pressing CRTL + b shows the bookmark window?
Yes.

Quote:And when pressing "b" could there be something like a confirmation sound / window, so I know the bookmark is really created?
Add the following statement to the bottom of your setbookmark.py script:
Code:
xbmc.executebuiltin('XBMC.Notification(Attention:, Bookmark added, 3)')
Reply
#25
Quote:It doesn't appear your notebook keyboard has dedicated buttons for Home/End and PgUp/PgDn (the photos are small and I can't read the German(?) labels on the keytops). The problem is that toggling the NumLock doesn't change the key presses on the numeric pad as far as XBMC is concerned. For example, pressing the number 7 on the keypad sends numpadseven, regardless of whether or not NumLock is enabled.
Sorry for the small photos, yes, no such keys on my keyboard. I have multi media keys (like stop / pause, next).

Quote:This example remaps some of the numeric pad numbers to these actions. Change accordingly if you prefer to use some of the F1-F12 keys or some others.
Ah yes, thank you, it works, great.


Quote:Can I combine the code of zepo and your's, so e.g. pressing "b" creates a bookmark and pressing CRTL + b shows the bookmark window?

Yes.
This also works.


Quote: And when pressing "b" could there be something like a confirmation sound / window, so I know the bookmark is really created?

Add the following statement to the bottom of your setbookmark.py script:
And this works, too.

Very good, all the shortcuts work like I want them to work.

Many, many thanks for your help
Reply
#26
The sound when a bookark is created doesn't play anymore, how could I correct it?
Newest stable Kodi (portable), Win 10 | skin: default Confluence
Reply
#27
(2013-01-22, 16:22)zepo Wrote: To set a bookmark with one key you can use a script like this I found in the forums:

Code:
import xbmc, xbmcgui

xbmc.executebuiltin('xbmc.ActivateWindow(videobookmarks)')
xbmc.executebuiltin('SendClick(10125,2)')
xbmc.executebuiltin('xbmc.action(previousmenu)')

Save the script as "setbookmark.py" and edit your keyboard.xml

<b>RunScript(/PATH/TO/SCRIPT/setbookmark.py)</b>

To go to the top/bottom of a list use FirstPage and LastPage and map them to a key of your choice

e.g

<f1>FirstPage</f1> and <f2>LastPage</f2>

That should do what you want.

Thank you, thank you, thank you!
Reply
#28
(2013-01-22, 16:22)zepo Wrote: To set a bookmark with one key you can use a script like this I found in the forums:

Code:
import xbmc, xbmcgui

xbmc.executebuiltin('xbmc.ActivateWindow(videobookmarks)')
xbmc.executebuiltin('SendClick(10125,2)')
xbmc.executebuiltin('xbmc.action(previousmenu)')

Save the script as "setbookmark.py" and edit your keyboard.xml

<b>RunScript(/PATH/TO/SCRIPT/setbookmark.py)</b>

If you don't mind, can you provide some help on how to script o jump to next bookmark and bind it to a key. Bookmarks are stored in database so it should be possible to read it from it for a playing video and then do some trick to jump to next!
Reply

Logout Mark Read Team Forum Stats Members Help
Shortcut creating bookmarks?0