Hi again,

----- Mikko Vartiainen <[email protected]> a écrit :
> > Is MAEMO a true define made by any build toolchain or a define you made 
> > yourself (first one most probably)?
> 
> I just made it myself. Toolchain doesn't automatically use any special 
> defines.

I was told that maybe the macro MAEMO5 exists. A quick google shows no code 
using it though.

Therefore, I'm wondering how we should handle this. You probably use the 
configure scripts, which can updated to detect Maemo. Probably ${host} variable 
has enough maemo specific things, and we can add on the fly the needed defines 
to the CFLAGS. Another possibility is adding them to the generated 
config_autotools.h, which brings us to this topic from our private discussion:

*hackish edit*
> One way (possibly too complicated) would be to have own
> define for each feature such as DISABLE_FEATUREX and then maemo and
> android (and other possible targets) would have their own profile
> defined somewhere. Simpler way would just to change the things which
> are common to HANDHELD or TOUCHSCREEN and have the rest as separate
> defines.

My reply was (slightly edited):
Yes, DISABLE_FEATUREX is the nicest way, but it may be tricky to determine all 
the conditions properly. In the end this might be over-engineered, but this 
needs further investigations.

So the later was my intent initially: KISS solution.

I think we can do this, either through editing the CFLAGS or adding HAVE_* to 
the generated header.

> > - the control widget shouldn't even add them to the list of displayed things
> 
> Reason I made it this way is that using keyboard bindings menu clears
> all previous bindings. So on startup special controls are read from
> xml file and when bindings are changed they are "injected" in.
> Currently anything which is defined in keyboard.cpp is whiped when
> bindings menu is used.

Ah yes, you're right, I forgot I'm erasing all of the bindings when saving, not 
just the ones set. But then this is a bug in control config, it shouldn't do 
this.

> Maybe Keyboard::SetDefaultConfig() could be used?

I think we should be resilient rather than stomping onto a problem and seeing 
the previous solution isn't perfect. I was bitten several times by this when 
editing control config, and I will probably continue in spite of me, but I 
think we should have ControlItem::SaveAction erase the initial binding then add 
its own.

> N900 has two different keyboard layouts regarding arrow keys. UK/US
> version has normal arrow keys[1] and every other version[2] has
> up/down done via fn key. Previously when it wasn't possible to change
> keyboard bindings I could just define extra binding in default xml
> file.
> 
> [1] 
> http://cellulari.tecnocino.it/wp-galleryo/nokia-n900-rover/nokia_n900_rover.jpg
> [2] 
> http://www.telefonino.net/new_files/images/global/Nokia-N900-847_44600_1.jpg

Can this be detected? If yes, and under a specific MAEMO-protected code block, 
maybe we should try handling this.

> We can continue our discussion on this list too, no problem.

I hope our mails didn't cross and you didn't reply to my private mail.

From now on, let's continue the handheld discussions here too.

Thanks again and best regards,
Christophe

_______________________________________________
Wormux-dev mailing list
[email protected]
https://mail.gna.org/listinfo/wormux-dev

Répondre à