On Feb 13, 2008 12:40 PM, MythTV &lt;<a href="mailto:mythtv@cvs.mythtv.org">mythtv@cvs.mythtv.org</a>&gt; wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
#4658: Lirc Improvment<br>-------------------------+--------------------------------------------------<br>&nbsp;Reporter: &nbsp;xavier &nbsp; &nbsp; &nbsp; | &nbsp; &nbsp; &nbsp; Owner: &nbsp;ijr<br> &nbsp; &nbsp; Type: &nbsp;enhancement &nbsp;| &nbsp; &nbsp; &nbsp;Status: &nbsp;new<br>&nbsp;Priority: &nbsp;minor &nbsp; &nbsp; &nbsp; &nbsp;| &nbsp; Milestone: &nbsp;unknown<br>
Component: &nbsp;mythtv &nbsp; &nbsp; &nbsp; | &nbsp; &nbsp; Version: &nbsp;unknown<br>&nbsp;Severity: &nbsp;medium &nbsp; &nbsp; &nbsp; | &nbsp; &nbsp; Mlocked: &nbsp;0<br>-------------------------+--------------------------------------------------<br>&nbsp;Hi,<br><br>&nbsp;I am trying to improve lirc support in myth:<br>
&nbsp;My goal is :<br>&nbsp;- to be able to configure lirc without simulating QKeyEvent<br>&nbsp;- To get ride of the .lircrc and use the socket which should make easier<br>&nbsp;to configure (without restarting mythtv)<br>&nbsp;- to be able to program each remote control differently (as long as their<br>
&nbsp;are not the same make)<br>&nbsp;- Potentially each Input would be configurable individually<br><br>&nbsp;This patch is just a draft.<br>&nbsp;I implement the MythInputEvent as well as the child class MythLircEvent<br>&nbsp;(future class could be MythKeyEvent,MythKeyExternalEvent...)<br>
&nbsp;I create the inputEvent method only in mythmenuthemed as a example.<br><br>&nbsp;If well written, this patch could also make MythMainWindow unaware of the<br>&nbsp;different kinds of InputEvent (remove some ifdef ...).<br><br>&nbsp;If adopted, Widget would have to use inputEvent methods to handle it and<br>
&nbsp;get rid of the keyPressEvent<br><br>&nbsp;I still need :<br>&nbsp;- to create the MythKeyEvent (which will encapsulate a QKeyEvent) and<br>&nbsp;redirect the main keyPressEvent to inputEvent<br>&nbsp;- make the jump work the same way<br>&nbsp;- replace my dirty mapping in keyContext by something else<br>
<br>&nbsp;I am facing few problem also:<br>&nbsp;- I am not to sure how to manage the retro compatibility, maybe by using<br>&nbsp;the old way if a .lircrc file is found ?<br>&nbsp;- To make this work, I have to replace all keyPressEvent method by<br>
&nbsp;inputEvent, And there is quite a lot :). Any idea to allow some kind of<br>&nbsp;cohabitation?<br><br>&nbsp;Is there a chance that such patch would be applied (when it will be<br>&nbsp;finished and clean of course) or do I waste my time?<br>
<br>&nbsp;The bz2 contain the diff file, the mythinputevent file and an example of<br>&nbsp;keybindings table<br><br>&nbsp;I did change my keybinding table too:<br>&nbsp;- add a column input which should include &#39;keyboard&#39;, &#39;lirc&#39; as retrieved<br>
&nbsp;by MythInputEvent::getInputName<br>&nbsp;- replace the primary key on context,action,hostname by<br>&nbsp;context,action,hostname,input<br><br>&nbsp;I wonder if this primary key is a good idea as we could have a primary key<br>&nbsp;as context,action,hostname,input,keylist and have only on bindings per row<br>
&nbsp;(in keylist i mean). The present modele us QKeySequence which have a<br>&nbsp;limitation of 4 QKeyEvent, I don&#39;t this this limitation is a good idea. To<br>&nbsp;have only on key per keylist would simplify the parsing too.<br>
<br>&nbsp;No change have been done in MythControl neither, Is there any reason to<br>&nbsp;have MythControl as a plugin ? Would be better to have this in the core,<br>&nbsp;Each plugin/dialog/context could be configurable from their menu (may be<br>
&nbsp;in the help page). it make more sense for the user point of view and it<br>&nbsp;would be also easier to bind a missing key quickly without quiting what<br>&nbsp;the user is doing.<br><br>&nbsp;Any review, suggestion would be a great help.<br>
<br><br>&nbsp;Regards,<br>&nbsp;Xavier<br></blockquote></div><br>It&#39;s not clear to me what problem exists that this will fix.<br><br>Lirc works fine for me now.&nbsp; This looks like this could break my existing setups.<br><br>If there is a real problem that needs to be solved, I am all for that.&nbsp; But if it is not broken, let&#39;s not fix it.&nbsp; There are plenty of real problems that could use attention.<br>
<br>Tom<br>