Lirc input

Discussion about user contributed plugins

Moderator: Moderator

Fredde
veteran
Posts: 288
Joined: Tue Dec 06, 2005 7:18 am
Location: Sweden

Lirc input

Postby Fredde » Sat Feb 23, 2008 11:30 am

I checked the code in plugins/input/lirc/lirc.cpp

Code: Select all

...
if (accept_all) {

      Input i;

      if (found_input)
        if (temp.mode == "search" || temp.mode == "general")
          i = temp;

      i.key = irdata.key;
      input = i;

    } else {
      if (found_input)
        input = temp;
      else
        goto nogood;
    }
...


If I use input mode lirc and have called the method enable_all_input and the input map is not search or general, the input command attribute will always be empty. This is not true for input mode keyboard. Is there any special reason for this behaviour?

User avatar
arj
Site Admin
Posts: 2316
Joined: Thu Dec 01, 2005 8:51 pm
Location: Denmark
Contact:

Postby arj » Sat Feb 23, 2008 2:14 pm

The reason I think is that the layout of a remote is much more limited. Meaning that some of the keys that are normally mapped to 1-9 will have to be disabled in search mode (enable all input). So that's why we mask on search and general.

The question of why this is not done for keyboard I think is a bug. I have committed a fix into 1.1.0 that makes keyboard behave like lirc.

User avatar
acmelabs
Overlord
Posts: 2365
Joined: Mon Feb 20, 2006 9:18 pm
Location: Germany
Contact:

Postby acmelabs » Sat Feb 23, 2008 2:50 pm

arj wrote:The reason I think is that the layout of a remote is much more limited. Meaning that some of the keys that are normally mapped to 1-9 will have to be disabled in search mode (enable all input). So that's why we mask on search and general.

The question of why this is not done for keyboard I think is a bug. I have committed a fix into 1.1.0 that makes keyboard behave like lirc.

So this is what this patch is all about?

Code: Select all

[15:20] <CIA-24> mms: arj * r1449 mms-1.1.0/plugins/input/keyboard/keyboard.cpp:
[15:20] <CIA-24> mms: Screen out keys that are not search and general in keyboard search
[15:20] <CIA-24> mms: Thanks Fredde for the find


Regards,
Andreas


Return to “user plugins”

Who is online

Users browsing this forum: Baidu [Spider] and 1 guest