Search
lxdream.org :: lxdream :: r917:2146dd5529fd
lxdream 0.9.1
released Jun 29
Download Now
changeset917:2146dd5529fd
parent916:6fbba9e71516
child918:7ab30c886553
authornkeynes
dateFri Nov 07 07:53:31 2008 +0000 (15 years ago)
Fix "0" being confused with "not defined"
src/drivers/genkeymap.pl
1.1 --- a/src/drivers/genkeymap.pl Fri Nov 07 07:39:52 2008 +0000
1.2 +++ b/src/drivers/genkeymap.pl Fri Nov 07 07:53:31 2008 +0000
1.3 @@ -27,7 +27,7 @@
1.4 print "const gchar *${name}_keysyms_by_keycode[128] = { ";
1.5 for( $i=0; $i < 128; $i++ ) {
1.6 if( $i != 0 ) { print ", "; }
1.7 - if( $hash{$i} ) {
1.8 + if( defined($hash{$i}) ) {
1.9 print "\"$hash{$i}\"";
1.10 } else {
1.11 print "NULL";
1.12 @@ -38,7 +38,7 @@
1.13 print "const uint16_t ${name}_keycode_to_dckeysym[128] = { ";
1.14 for( $i=0; $i<128; $i++ ) {
1.15 if( $i != 0 ) { print ", "; }
1.16 - if( $hash{$i} && $dcsyms{$hash{$i}} ) {
1.17 + if( defined($hash{$i}) && $dcsyms{$hash{$i}} ) {
1.18 print $dcsyms{$hash{$i}};
1.19 } else {
1.20 print "DCKB_NONE";
.