• 1
  • 19
  • 20
  • 21(current)
  • 22
  • 23
  • 47
[RELEASE] Chrome Launcher
Is it possible to include a keymap configuration for chrome launcher in userdata/keymaps/xxx.xml

I already have keymaps setup for wiimote which works great in xbmc, but is it also possible to add a map for chrome launcher ??

Is it possible to enable the virtual Keyboard in ChromeLauncher, or possibly add a new map something like:

<ChromeLauncher>
<joystick name="WiiRemotePAC">
<button id="6">Shift</button>
<button id="7">CursorLeft</button>
<button id="9">CursorRight</button>
<button id="10">Symbols</button>
<button id="11000">BackSpace</button>
</joystick>
</ChromeLauncher>
Reply
(2013-12-25, 02:14)rob hodge Wrote: hello-

i wanted to throw an idea out there as a suggestion to fix the issues that people are having with this plugin and XBMCbuntu, as i ran into this before with my the emulators that i have setup, as well as the compoholio ubuntu-netflix i had been running with.

to have focus grabbed and to go full-screen when yo have a second program running, you need to be running a window manager, as this is the part of the desktop environment that manages what programs are on the screen, and who gets control and focus and all that. i use open box, as this comes installed with the xbmcbuntu installation as it is what the xbmcbuntu desktop environment mode uses. all XBMCbuntu installs ship with it.
to return to XBMC gracefully, you then need to kill the window manager after the program (chrome) ends.

on my emulators i do this via this script:
Code:
#!/bin/bash
openbox &
$1
kill 1%

line-by line, what this does is:

Code:
#!/bin/bash
identify this is a bash script

Code:
openbox &
launch openbox. the '&' means execute in background, and move to the next line

Code:
$1
the $1 means execute the first command line parameter passed to it. since this is run foreground, the script waits for this to exit before executing the next line

Code:
kill 1%
the 'kill %1' tells it to kill the first child process launched by this script that is running in the background. (openbox)

so, if i call this 'launcher' by executing
Code:
launcher  "emulator --paramaters --romname --etc"

it runs "emulator --paramaters --romname --etc" inside a 'wrapper' of the script that opens the window manager, runs "emulator --paramaters --romname --etc", and (once 'emulator' closes) closes the window manager. Everything works perfectly and transparently.

would it be possible to implement a method to use this in chrome launcher?
perhaps instead of a 'execute script before' option, an 'execute script and pass command as a parameter' option? this would allow us to write a script that would run on both sides of chrome, both setting up and deconstructing any environment or helper programs needed, as well las making it much more customizable.

or, for a more idiot proof option that wouldn't require scripting knowledge, an option to chose a window manager to have chrome launcher open and close before and after chrome?

this execute window manager / execute app / kill window manager process is pretty much essential to launch any program from within XBMCbuntu and have your control and focus work properly. implement this procedure, and most of the issues you hear from XBMCbuntu users would evaporate.

there is a kludge i've come up with to get things working as is;

it's this script run from within chrome launcher:
Code:
#!/bin/bash
openbox &
sleep 30
pids= pidof chromium-browser
wait $pids
kill %1
this runs open box
waits 30 seconds
gets the Program id's of all the chromium processes
tells the script to wait untill all the chromium processes have terminated
then kill open box.

it is a hack; there is a potential race condition. if chromium doesn't open within 30 seconds of the start of the script, it wil ljust kill open box and exit, leaving the system kinda borked. i haven't had this happen, but it's why i'd rather launch chromium from within the script.

I know this is kind of old but couldn't you do a while loop checking for chrome process. I would set a max execution. So if chrome never starts the script will exit eventually.
Reply
Does anyone know of a more charming way to close Chrome/Youtube on Windows? Alt + F4 or ctrl + W is fine for me but less savvy computer users tend to close XBMC too. If XBMC is set up as shell they're kinda stuck and have to restart the computer.
Reply
Hi,

Is it possible to make optional the use of black.html javascript to launch site, and pass the url on the command line instead, if the option is disabled ?

I'm trying to use a sandboxed Chrome in a docker container (see https://github.com/jlund/docker-chrome-pulseaudio for details) and it doesn't work because of black.html trick.
Reply
Hi,

I was experiencing the "half-screen" issue with the Chrome launcher. I did try a lot of the suggested solutions on this topic, but non of them worked. Luckily I came across a configuration file of Google Chrome, which allows you to set the initial position and size of the window. This is how I solved it (using SSH):

Open the file "/home/kodi/.config/google-chrome/Default/Preferences" in an editor (my current user is called kodi).

Now edit the window position and size (my screen resolution is 1360x768):
Code:
...
            "item_type": 1,
            "name": "Gmail",
            "parent_id": "",
            "position": "nyn"
         }
      }
   },
   "browser": {
      "window_placement": {
         "bottom": 768,
         "left": 0,
         "maximized": false,
         "right": 1360,
         "top": 0,
         "work_area_bottom": 768,
         "work_area_left": 0,
         "work_area_right": 1360,
         "work_area_top": 0
      }
   },
   "countryid_at_install": 21843,
...

I also changed the Chrome launcher script as I don't need openbox (/home/kodi/.kodi/addons/plugin.program.chrome.launcher/script.sh):

Code:
#!/bin/bash
#openbox &
/usr/bin/google-chrome --no-proxy-server "$@"
#kill %1

The usage of this custom script is enabled in the "Chrome Launcher' addon settings in Kodi. I have the "Use own user profile" option set to disabled.

I hope this solution helps other people in solving the issue.

Regards,
Sander
Reply
Kodi doesn't reopen after I alt+F4 chrome. I'm guessing it's looking for XBMC.exe instead of Kodi.exe? Any way to fix this without renaming Kodi.exe?
Reply
Stop guessing and provide logs!
If I have helped you or increased your knowledge, click the 'thumbs up' button to give thanks :) (People with less than 20 posts won't see the "thumbs up" button.)
Reply
(2015-03-02, 04:10)nickr Wrote: Stop guessing and provide logs!

Yeah sorry, here you go: http://xbmclogs.com/p7ejsv9rr

Hope I did it correctly!

Edit: Tried renaming to XBMC.exe and it did not solve the problem. I assumed that was the problem because someone mentioned it in an earlier post.
Reply
some 1 else experience freezing in this plugin?

I'm using ubuntu 14.04 whit latest kodi nightly and when I', using plugin.program.chrome.launcher then some times (maybe once a day) this plugin freezes, I cant quit program (ctrl+w) today I quit session but the plugin had freezed and I cant select another site or cant go back whit esc, however the pc havent freezed because I managed to got another desktop and to other things (ctrl+alt+narrow)

only way is reboot system
Reply
(2015-02-21, 16:14)jknight2014 Wrote:
(2013-12-25, 02:14)rob hodge Wrote: hello-

i wanted to throw an idea out there as a suggestion to fix the issues that people are having with this plugin and XBMCbuntu, as i ran into this before with my the emulators that i have setup, as well as the compoholio ubuntu-netflix i had been running with.

to have focus grabbed and to go full-screen when yo have a second program running, you need to be running a window manager, as this is the part of the desktop environment that manages what programs are on the screen, and who gets control and focus and all that. i use open box, as this comes installed with the xbmcbuntu installation as it is what the xbmcbuntu desktop environment mode uses. all XBMCbuntu installs ship with it.
to return to XBMC gracefully, you then need to kill the window manager after the program (chrome) ends.

on my emulators i do this via this script:
Code:
#!/bin/bash
openbox &
$1
kill 1%

line-by line, what this does is:

Code:
#!/bin/bash
identify this is a bash script

Code:
openbox &
launch openbox. the '&' means execute in background, and move to the next line

Code:
$1
the $1 means execute the first command line parameter passed to it. since this is run foreground, the script waits for this to exit before executing the next line

Code:
kill 1%
the 'kill %1' tells it to kill the first child process launched by this script that is running in the background. (openbox)

so, if i call this 'launcher' by executing
Code:
launcher  "emulator --paramaters --romname --etc"

it runs "emulator --paramaters --romname --etc" inside a 'wrapper' of the script that opens the window manager, runs "emulator --paramaters --romname --etc", and (once 'emulator' closes) closes the window manager. Everything works perfectly and transparently.

would it be possible to implement a method to use this in chrome launcher?
perhaps instead of a 'execute script before' option, an 'execute script and pass command as a parameter' option? this would allow us to write a script that would run on both sides of chrome, both setting up and deconstructing any environment or helper programs needed, as well las making it much more customizable.

or, for a more idiot proof option that wouldn't require scripting knowledge, an option to chose a window manager to have chrome launcher open and close before and after chrome?

this execute window manager / execute app / kill window manager process is pretty much essential to launch any program from within XBMCbuntu and have your control and focus work properly. implement this procedure, and most of the issues you hear from XBMCbuntu users would evaporate.

there is a kludge i've come up with to get things working as is;

it's this script run from within chrome launcher:
Code:
#!/bin/bash
openbox &
sleep 30
pids= pidof chromium-browser
wait $pids
kill %1
this runs open box
waits 30 seconds
gets the Program id's of all the chromium processes
tells the script to wait untill all the chromium processes have terminated
then kill open box.

it is a hack; there is a potential race condition. if chromium doesn't open within 30 seconds of the start of the script, it wil ljust kill open box and exit, leaving the system kinda borked. i haven't had this happen, but it's why i'd rather launch chromium from within the script.

I know this is kind of old but couldn't you do a while loop checking for chrome process. I would set a max execution. So if chrome never starts the script will exit eventually.


none of the old fixes for XBMCbuntu will work as of 14.0

the way Kodi does the display has changed; before it was done via SDL, now it is native X11.

the way i resolved it was to add openbox to the init scripts for Kodi, so it is always running. less elegant than the launchers, but the only way i could get it to go.

if you launch openbox via a script like the old methods i wrote and like is included in the custom script, it does not get controll over all the applications and is kinda messy. in the curent setup, openbox needs to be open before kodi is.
Reply
(2015-03-07, 05:46)rob hodge Wrote: none of the old fixes for XBMCbuntu will work as of 14.0

the way Kodi does the display has changed; before it was done via SDL, now it is native X11.

the way i resolved it was to add openbox to the init scripts for Kodi, so it is always running. less elegant than the launchers, but the only way i could get it to go.

if you launch openbox via a script like the old methods i wrote and like is included in the custom script, it does not get controll over all the applications and is kinda messy. in the curent setup, openbox needs to be open before kodi is.

Just arriving to this party and trying to get this working. Could you elaborate on where/when/how you're currently launching openbox? Would be so helpful since I just spent a few hours trying everything from the first several pages of this thread. Smile

Thanks!
Reply
Reply
p.s. CTRL+W exits on Linux

I also added a netflix launcher to the default script (you'll need to download a 256x256 netflix PNG image and put it in the same directory as the script for the icon)

youtubeUrl = "http://www.youtube.com/leanback"
vimeoUrl = "http://www.vimeo.com/couchmode"
netflixUrl = "http://www.netflix.com"


...

addDir("[ Netflix ]", netflixUrl, 'showSite', os.path.join(addonPath, "netflix.png"), "yes", "yes")
addDir("[ Vimeo Couchmode ]", vimeoUrl, 'showSite', os.path.join(addonPath, "vimeo.png"), "yes", "yes")
addDir("[ Youtube Leanback ]", youtubeUrl, 'showSite', os.path.join(addonPath, "youtube.png"), "yes", "yes")
Reply
Hello..

I'll keep it short.. I think I speak for a lot of people who are getting in the the scene that the level of debate here is rather complicated for a noob.

I'm just getting in to programming and really enjoying it but I hope that somebody will take their time to explain to us who don't quite follow.
I've read through this whole thread (yea it took a long time). At many places people ask basic questions without getting replys. I understand that that's not what the thread is about, Progress is what you guys are here for hehe.. But I ask you..

For those of us who don't even get the program running. Where it either says: Missing Info, and then opens the settings box for Chrome launcher OR "script failed". No matter what file one chooses in the custom script path...

I'm running the latest update of Helix, with Chrome Launcher 1.1.4.

This wasn't short sorry. Have a great day! Thanks for all the progress!
Reply
I don't think it's nessarry to read the whole thread, you should read the first post of this thread, all needed information is there.
What system do you use? Not all systems are supported.
Did you install the test repo?
Reply
  • 1
  • 19
  • 20
  • 21(current)
  • 22
  • 23
  • 47

Logout Mark Read Team Forum Stats Members Help
[RELEASE] Chrome Launcher8