INTERACT FORUM

More => Old Versions => JRiver Media Center 26 for Windows => Topic started by: sking29 on March 29, 2020, 07:02:08 pm

Title: Is it possible to cause space bar to NOT start and stop player
Post by: sking29 on March 29, 2020, 07:02:08 pm
If so, how?  Thanks !!!
Title: Re: Is it possible to cause space bar to NOT start and stop player
Post by: RoderickGI on March 29, 2020, 07:26:25 pm
Yes. I think.

Research "Resource.xml" and how to use it.

Although there is a lot of functionality around the humble Spacebar that may have been coded separately into the program. Try it and see.

Hint:     <Entry Key="Space" Command="10000" Param="-1" TranslateFlags="401" />


Also, why? I find hitting the spacebar to Pause/Play something very useful. Lots of other programs use the same functionality, like YouTube videos for example.
Title: Re: Is it possible to cause space bar to NOT start and stop player
Post by: MusicBringer on March 30, 2020, 09:05:58 am
Quote
If so, how? 
What a great question. I have no wish to cease playing my music, yet far too often the spacebar gets knocked by accident and I wonder why its all gone quiet. Sometimes I can be using another program and touching the spacebar interrupts my music. Grrhh.
Title: Re: Is it possible to cause space bar to NOT start and stop player
Post by: sking29 on March 30, 2020, 10:13:19 am
yet far too often the spacebar gets knocked by accident


Exactly what happens to me. 

Roderick or others, thanks for the hints.  Can you go a little further?  How would the header of the file be formatted, etc.  Is there an example I can follow?
Title: Re: Is it possible to cause space bar to NOT start and stop player
Post by: RoderickGI on March 30, 2020, 06:44:17 pm
Okay, the simple answer, assuming that you are using the 64bit version of MC26.

Close MC and MC Media Server, if they are running.
Navigate to "C:\Program Files\J River\Media Center 26\Data\Default Resources" using Windows Explorer.
Find the file "Resource.xml" and make a copy of it. Leave the copy in the same directory as above, just in case you have problems or want to revert later.
Edit the "Resource.xml" file with Notepad or similar.
Find the <Entry Key="Space" Command="10000" Param="-1" TranslateFlags="401" /> line in the file.
Edit that line and change it to;
<!-- <Entry Key="Space" Command="10000" Param="-1" TranslateFlags="401" /> -->
The above comments out that line.
Save the change and restart MC.

Test whether the Spacebar still Pauses and Plays media. It shouldn't, but I haven't tested. The TranslateFlags="401" may mean more needs to be done, because 401 is achieved by 256+128+16+1 (refer to green test in "Resource.xml" file), which should mean that spacebar doesn't work in Theatre View. But it does.  ?  This is why I suspect some Spacebar functionality is hard codes, rather than controlled by the "Resource.xml" file.


Slightly longer version.
Instead of editing the original "Resource.xml" file you can create a new directory "C:\Program Files\J River\Media Center 26\Data\Custom Resources".
Then copy the original "Resource.xml" to the new "Custom Resources", and edit that copy.

MC should use the "Custom Resources" version of the "Resource.xml" file, and hence the Spacebar should no longer Pause and Play media.
Using the "Custom Resources" directory means that future updates won't overwrite the standard (original) "Resource.xml" file, so your fix remains in place. While updates are covered, future upgrades to new major versions will require you to copy the "Custom Resources" directory into the new location for the new MC version. i.e.  "C:\Program Files\J River\Media Center 27\Data\Custom Resources".


A search of the forum for "Resource.xml" will find lots of information. A search for "Resource.xml Custom" will narrow the search.