History log of /haiku/src/preferences/keymap/KeymapWindow.cpp
Revision Date Author Comments
# bd514095 24-Mar-2019 Oishika Pradhan <oishikapradhan@gmail.com>

Keymap: better default window size.

Use a larger default window size so the keymap is readable.
However, size it down on low resolution displays.

Fixes #14892

Change-Id: Id35c46fa14bef570f78d8f065d95f6e6d8f0c6d7
Reviewed-on: https://review.haiku-os.org/c/haiku/+/1312
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 77fb9ca3 14-Aug-2019 Murai Takashi <tmurai01@gmail.com>

Keymap: Localize keyboard layout menu.

and modify keyboard_layouts/Jamfile to remove "<keyboard-layout>"
from KeyboardLayoutNames.h.

Change-Id: Ibd68bfa165089e77cfeb6ade17f6135ac5608b46
Reviewed-on: https://review.haiku-os.org/c/haiku/+/1719
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 84a5d9f6 25-Jul-2019 Murai Takashi <tmurai01@gmail.com>

Keymap: localize system keymap list

Change-Id: Ifd8e7c2b4a8d1f48ce31686b3b653d0304b4c635
Reviewed-on: https://review.haiku-os.org/c/1649
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# 16e50860 23-Dec-2018 Humdinger <humdingerb@gmail.com>

Keymap: remove item from user list, if the keymap isn't found

Fixes #4022.

When a user keymap was deleted in Tracker while the Keympas prefs
are open, the map is still visible in the list of user maps. It
just doesn't react on a click.

With this change, we just silently remove the item from the user map
list when it's clicked. Not totally nice (should I add a BAlert?),
but the suggested node monitoring for this seldomly encountered
situation is overkill, I think.

Change-Id: I5ea6dd2aa117f30a7be348a005a10f3757d52459
Reviewed-on: https://review.haiku-os.org/794
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# 23a6a63e 19-Aug-2016 John Scipione <jscipione@gmail.com>

Keymap: Follow symlink

get_ref_for_path() doesn't resolve symlinks.

Construct a BEntry from the path passing 'true' for the traverse
argument. That BEntry is then be passed to BDirectory's constructor.

The error was hidden by the fact that the code didn't bother to error
check the result of get_ref_for_path(), which would have indicated that
the passed in path was a link.

Thanks Rene for your help.

if the entry fails to init, we are probably screwed, but, try to get
the path using get_ref_for_path in that case. Worst case scenario it
fails as well and the FilePanel points to your home directory.


# 3d2f4db5 19-Aug-2016 John Scipione <jscipione@gmail.com>

Keymap: Reinitialize ref after creating Keymap dir

In the case that the Keymap directory does not exist and has to
be created, reinitialize ref to the newly created directory.

Thanks Stippi for your help

There is still a bug present where if the Keymap directory is a
symlink to another directory, the File Panel does not follow that
link and instead opens to your home directory. More on this later.


# 29f04e86 19-Aug-2016 John Scipione <jscipione@gmail.com>

Revert "Keymap: Handle uninitialized ref"

This reverts commit 1e5f78f522bbdbd9af987df452d756cee4f6d32f.


# 1e5f78f5 18-Aug-2016 John Scipione <jscipione@gmail.com>

Keymap: Handle uninitialized ref

...trying to get/make Keymaps settings dir if not able to create
the Keymaps directory under settings.

Resolve symlink, if it is a directory, use that directory instead,
otherwise use home directory as a fallback.


# 661e7652 17-Aug-2016 John Scipione <jscipione@gmail.com>

Revert "Keymap: Check return value of get_ref_for_path"

This reverts commit 14698e043233c4fb0f783993d0c874c8241eff77.


# e8fc10de 16-Aug-2016 John Scipione <jscipione@gmail.com>

Keymap: Refactor _LoadSettings()

Instead of filling out the path into a BString and using it in the calling method,
call _SetKeyboardLayout() directly using the path found.

Also use a plain const char* array instead of BString because we don't need
the added functionality.

The return value now reflects whether or not the window frame was loaded.

Check the return value on the caller side and only use the resulting window
frame if it is B_OK, otherwise CenterOnScreen().


# ec55352e 16-Aug-2016 John Scipione <jscipione@gmail.com>

Keymap: Fix saving keyboard layout

The function would stop prematurely after the first submenu whether it
found a layout or not.

Now stop when you have has an initialized path or end of menu

Fixing saving keyboard layout also fixes loading layout which fixes #3918

How did this silly bug live so long?


# 14698e04 16-Aug-2016 John Scipione <jscipione@gmail.com>

Keymap: Check return value of get_ref_for_path

if not B_OK, create BFilePanels with default directory

This should never happen but better than crashing on a NULL ref


# 2fd8e281 12-Aug-2016 John Scipione <jscipione@gmail.com>

Keymap: Add layout files to beginnning of menu

...so they are sorted alphabetically.


# d0ac6099 07-Nov-2015 Humdinger <humdingerb@gmail.com>

Use B_USE_WINDOW_SPACING

Use B_USE_WINDOW_SPACING as inset from contents to window border.
Some whitespace cleanup.


# 881325a0 14-Sep-2015 Axel Dörfler <axeld@pinc-software.de>

Keymap: improve initial window size, and position.

* By making it scale with the font size, and by using
BWindow::MoveOnScreen().


# b433c2ad 07-Jan-2015 John Scipione <jscipione@gmail.com>

Keymap: Add ability to remove a key mapping

... of a normal (non-modifier) key via a right click menu.


# 5e96d7d5 21-Feb-2014 John Scipione <jscipione@gmail.com>

Localize keyboard layout names in Keymap preferences


# 374cf8c8 13-May-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Localize keymap names in Keymap preferences


# a073305c 19-Feb-2014 John Scipione <jscipione@gmail.com>

keymap: limit set of left/right swap options

For Shift, Control, Option, and Command assume that you want to shift
on the same side, left-for-left, right-for-right. The Menu key is
available on either the left or right side, and lock keys can be
swapped with any other modifier left or right.

If we have multiple unmapped modifiers we need to do a little extra
work to figure out which of the unmapped modifiers to swap with.

Convert private class member methods to static functions.

Also update copyright info


# 8eb27eaa 04-Sep-2013 John Scipione <jscipione@gmail.com>

Keymap: Allow you to unset modifier keys

Selecting the marked menu item will unset the mapping for that modifier.

We can't rely on there being a unique mapping for a key (more than one
could be set to 0 aka unset) so we have to set the menu item names based
on the interface defs constants intead.


# c959ce46 12-May-2013 John Scipione <jscipione@gmail.com>

Some small style fixes


# 173b5a68 10-May-2013 John Scipione <jscipione@gmail.com>

Keymap: swap modifiers keys via context menu

When the user right clicks on a modifier key pop up a menu listing the
available modifiers. When the user selects a modifier from the menu swap
the key with the selected modifier. This provides an alternative way to swap
modifier keys other than drag&drop that works for just modifier keys.


# f6c5dbf8 03-Jan-2014 Humdinger <humdingerb@gmail.com>

Some more code style corrections of Keymap.


# 346c9923 03-Jan-2014 Humdinger <humdingerb@gmail.com>

Cleanup of KeymapWindow.cpp


# 803fab4f 02-Jan-2014 Humdinger <humdingerb@gmail.com>

Slightly improved layout of Keymap prefs

* use the templated BLayoutBuilder
* reduced top inset to be the same as to all sides
* SetExplicitMinSize of the LayoutView so it can't shrink to
illegibility
* set slightly smaller window default size (on small screens)


# c93efdb3 10-Nov-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Keymap preflet: Sort the lists


# 38fa81bf 03-Oct-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Remove B_COMMON*_DIRECTORY and kCommon*Directory constants

* This does intentionally break source compatibility, so that a review
of concerned code is forced.
* Binary compatibility should be maintained in most cases. The values
of the constants for the writable directories are now used for the
writable system directories. The values for the non-writable
directories are mapped to "/boot/system/data/empty/...", an empty or
non-existent directory, so that they will simply be skipped in search
paths. Only code that explicitly expects to find something in a
B_COMMON_* directory, will fail.


# 7889cac6 12-May-2013 John Scipione <jscipione@gmail.com>

Keymap: Add Defaults button to revert keymap

Fixes #9980

Since hrev44455 we save your modifier keys settings when you switch
keymaps so you could get your modifiers keys messed up and unable to
get back to normal. This Defaults button allows you to override all
that and go back to the default US-International keymap with default
modifiers so you can start with a fresh slate and set things up the
way you want.

Also moved Revert button to the left side next to the Defaults button.
We do this on other preflets, the right side is reserved for an Apply
or OK button, and, if the preflet doesn't have one, is left empty.


# 546208a5 16-Apr-2012 Oliver Tappe <zooey@hirschkaefer.de>

More catalog-related cleanup.

* rename B_TRANSLATE_CONTEXT to B_TRANSLATION_CONTEXT and
B_TRANSLATE_WITH_CONTEXT to B_TRANSLATE_CONTEXT, squashing a TODO
* adjust all uses of both macros in Haiku's source tree
* use correct header guard for collecting/Catalog.h

The renamed macros require adjustments to all external applications
using catalogs.


# 3cee15aa 28-Mar-2012 John Scipione <jscipione@gmail.com>

Keymap changes from recent activity. No AltGr yet.

Below is a mostly complete summary of the changes in this commit.

* Set the DeadKeys for the US-International Keymap to use the Option map.
* Rename American keymap to US
* Update the US, US-International, and United-Kingdom keymaps to take
out unneeded spaces in the option layer. Also updated the dead keys
and some other keys on the US-International keyboard to use UTF-8
characters rather than there ASCII equivalents when different.
* Make the Option key fall-through when there is no mapping in the Option
table. Option is for special characters, if none, print the regular one.
This is mostly meant for the US keymap which has an empty option map. But
also so that you don't have to repeat the normal, shift, and caps maps in
the option map needlessly. Although the keymaps are still not empty in
some cases that it could be like numpad keys and space.
* Update the /bin/keymap app to use fputs() instead of printf() when there
is no actual formatting taking place. I've gotten into trouble for doing
this before and it is faster to not process the string unnecessarily.
* Also several 80-char limit style fixes and updated comments.
* In Keymap class Reorder the modifier keys to match the keymap files.
Put B_CONTROL_KEY check above B_OPTION_KEY. Neither change has any effect,
they are purely aesthetic.
* Update DumpKeymap() method to use the abbreviated modifier letters so it
will fit in your 80-char wide terminal.
* Tiny style fix in InputServer
* 80-char limit style fix in BWindow and add a comment that the shortcut
gets eaten in the case of Cmd+Q
* Implement IndexForModifier() in KeyboardLayout, although I am not using it.
* Take Caps Lock out of the Modifier keys window because I couldn't get
it to work the way I wanted it to.
* Move key roles to the left column, and the key label on the left. Add column
header labels. Thanks Rimas!
* Add validation and improve marking menu options. Add a 'Disabled' option
to control, option, and command menus to disable the key. Make the key
role text grey if the key roles is disabled. Validation ensures that you
cannot repeat the same key twice in the Modifier keys window since that
won't work. You can't define 2 sets of option keys even if you really want
to. You can disable your control, option, and command keys if you
want, but that is not recommended.
* Rename kUpdateModifiers to kUpdateModifierKeys message to differetiate
it from kUpdateModifier.
* Add shift key to Modifier keys window, use the stop icon instead of the
warning icon to indicate conflicts.
* Allow the Layout system to control the size of the Modifier keys window
again, set the width's of the key role lables to the widest, set the width
of the menu fields to take up the rest of the space minus room for the
conflict views. I didn't like it that the Modifier keys window would change
size based on what options you had selected in the menu fields. Now it
doesn't, but, the layout system still makes it all fit.


# 1a6b60e6 25-Mar-2012 John Scipione <jscipione@gmail.com>

Addresses some of the issues brought up in ticket #8148

The key labels have been changed to Win/Option and Alt/Command
to better associate them with the key names on a PC keyboard. This is
not perfect, but, better.

Added a checkbox entitled "Switch right Alt/Command and Win/Option keys"
This checkbox does what it says, switches the keys on the right side
of your keyboard leaving the left side according to how you set them.
This is needed for some international keymaps.

Whether or not you have switched already is not remembered, you have to
check the box each time you open the dialog. I don't know how to figure
out whether or not the keys have been switched already reliably. Hopefully
this isn't a big deal.

Set the menu option and window title to sentence case, thanks Humdinger.


# bce949f5 07-Nov-2011 John Scipione <jscipione@gmail.com>

Implemented the style changes and other improvements suggested by Axel to the Keymap preference app Modifier Keys window. The number of lines of code in the class was significantly reduced by these changes. I also made one small change to change the window title from 'Modifers Keys' to 'Modifier Keys'.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43221 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f5ac2da0 07-Nov-2011 John Scipione <jscipione@gmail.com>

Adds a dialog to the Keymap preference app to more easily and
reliably change your modifier keys.

The dialog box is shown by selecting the new 'Set Modifier Keys...'
option under the File menu. This brings up a window which contains 4
dialog boxes labeled: Caps Lock, Control, Option, and Command.

Each of the labels in followed by a drop down box which allows you to select
from one of the other keys listed. So for instance you could switch the Caps
Lock and Control keys but selecting the 'Control' option next to Caps Lock and
the 'Caps Lock' option next to Control.

The Caps Lock menu has an additional option which I find appealing...
'Disable' which, as it sounds, disables your Caps Lock key.

At the bottom of the dialog there are 3 buttons, 'Cancel', 'Revert', and 'Ok'.
'Cancel' and 'Ok' are self explanatory. The 'Revert' button, which is
initially disabled, puts you back into the state that you were when you first
opened the dialog.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43210 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 08cd4bc2 01-Nov-2011 John Scipione <jscipione@gmail.com>

Add 3 new Apple Aluminum keyboard layout files and update and rename the
existing 'Apple Aluminium' keyboard layout to 'Apple Aluminium Extended
International.' The 3 new layout files are US mini and extended version
as well as an international mini version. This completes #7964

International corresponds to keyboard layouts for all locales except the US
and Japan. I have Japanese Apple Aluminum keyboard layout files almost
ready but I first need to determine what the special kana and eisu keys
are mapped to.

The Apple Aluminum keyboard layout files are tucked away in an Apple Aluminum
subdirectory. The Keymap preference app has been modified to turn
subdirectories into submenus of the Layout menu.

HaikuImage has been modified to include each keyboard layout file in the
image individually as recommended by Ingo.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43093 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 560ff447 25-Mar-2011 Jonas Sundström <jonas@kirilla.com>

Use resource definition files instead of DoCatalogs rule. Rename B_TRANSLATE_APP_NAME and related macros to the more generic B_TRANSLATE_SYSTEM_NAME, to also fits add-ons, folders, etc, and make 'System name' its standard context. Change CodyCam and PoorMan's app signatures to match the overall x-vnd.Haiku-App pattern. Some clean-up. Make SlideShowSaver build again.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41103 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d374a272 16-Mar-2011 Jonas Sundström <jonas@kirilla.com>

App name localization.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40980 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8f62243f 17-Aug-2010 Oliver Tappe <zooey@hirschkaefer.de>

* fix warnings in Keymap preflet about hidden virtual by renaming SetFont()
to SetBaseFont() (and fFont to fBaseFont)
* enabled -Werror for all preflets


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38203 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1fd91b7f 17-Aug-2010 Alex Wilson <yourpalal2@gmail.com>

Small compilation fixes for coming layout changes... (really!!)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38202 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4eb0cbb0 07-May-2010 Matt Madia <mattmadia@gmail.com>

Updated TR_CONTEXT to be B_TRANSLATE_CONTEXT, relating to #5408.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36733 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3d7bf37b 06-May-2010 Matt Madia <mattmadia@gmail.com>

Updated to use B_TRANSLATE* macros. relates to #5408.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36687 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b44c25de 16-Apr-2010 Axel Dörfler <axeld@pinc-software.de>

* Factored out a single base class out of the three Keymap implementations we
had in our tree.
* Adapted Keymap, <input>keyboard, and consoled to use it - the additional
functionality is implemented via a subclass in the first two cases.
* "keymap" will come next.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36328 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0b2fbbfa 24-Dec-2009 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

Patch by Humdinger to convert all the preference panels to sentance case.
Also update the localization catalogs as needed.
CPUFrequency localization is broken : the current code works, but the DoCatalogs jamrule is not powerful enough to properly extract the catkeys.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34767 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9c1a9b92 20-Dec-2009 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

* Patch by Humdinger to convert a lot of things to sentance case.
* Cleanup and update of all the touched catkeys files


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34731 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b10da4d8 27-Oct-2009 Axel Dörfler <axeld@pinc-software.de>

* _UpdateButtons() was called too early, before fCurrentMap, and fAppliedMap
were initialized, causing Keymap to lose the current map.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33808 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ad34440e 27-Oct-2009 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

-Removed unseless reference to adler32 in hashmapcatalog
-Localized Keymap preflet and translated it to french


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33790 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b01bdb48 17-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* The Keymap preferences app will now memorize its window frame and chosen
layout.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32491 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c5bf6169 17-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* When switching modifiers, the source key was not invalidated, making it appear
as if a copy happened. This closes bug #4242.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32490 a95241bf-73f2-0310-859d-f6bbb57e9c96


# aa0f32cf 12-May-2009 Oliver Tappe <zooey@hirschkaefer.de>

* removed KeymapMessageFilter, as it is no longer needed
* fixed a couple of issues with respect to internal/external naming of
keymaps and the respective files, hopefully such that there's always one
keymap active in the view: either one that has been selected or (Current)
if any changes have been applied
* replaced the dead-key-menubar with a menufield (thanks Axel, looking much
better)
cleanup:
* removed remnants of Use-button (message constant and switch-case)
* dropped 'Save' menu item, as it wasn't implemented anyway and would now
never be enabled
* removed fFirstTime, as it caused problems, but did not serve any purpose
anymore


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30734 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6be10e28 12-May-2009 Oliver Tappe <zooey@hirschkaefer.de>

* Removed the 'Use' button from the keymap preflet, since several people have
mentioned that they tend to forget pressing it (including me, of course), in
effect losing all changes.
The way the code currently works, having it didn't really make sense IMO,
as any change will only ever be applied to the "current" keymap. If you want
to keep your keymap more persistently, you need to save it into a named file,
anyway.
Please give it a try and shout if this is unacceptable.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30723 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 83936c1c 12-May-2009 Oliver Tappe <zooey@hirschkaefer.de>

* Added support for selecting the dead key trigger characters from a menubar,
offering two choices for acute and diaeresis as well as allowing to switch
off each dead key completely.
* moved the textview on a line of its own such that the dead key menu and
the modifier-switching button live together on one line
* added enum dead_key_index and used it at a couple of places instead of
having to use the magic numbers 1-5
* refactored the actual updating of the fChars buffer from SetKey() into
_SetChars(), which is now being invoked by SetDeadKeyTrigger(), too

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30718 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1e855c37 12-Apr-2009 Ingo Weinhold <ingo_weinhold@gmx.de>

* Patch by Fredrik Ekdahl: gcc 4 build fixes (missing headers).
* Added missing header for mountvolume.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30135 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6db2be32 05-Apr-2009 Axel Dörfler <axeld@pinc-software.de>

* Changed the way the shortcuts are switched: we no longer do the same thing
as BeOS on the right side (that is, switching control and option key), but
switch control and command there as well.
* As a consequence, the Alt-Gr key will stay where it is when switching the
shortcuts.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29929 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 317bd7dd 03-Apr-2009 Axel Dörfler <axeld@pinc-software.de>

* Changed directory structure as suggested on the mailing list.
* Made the TimeZoneView less error prone, and also actually use Haiku code (the
previous check didn't work since it used #if, not #ifdef).
* Also took the liberty to rename our boot loader to haiku_loader, since I had
to update the nasm binary anyway. Updated the assembly sources to nasm 2.0.
* I haven't found where the synth location in the MIDI code is specified,
though.
* Also, NetBootArchive, and FloppyBootImage haven't been updated yet. Will do
so next.
* Some optional packages still put their license to beos/etc/licenses. I didn't
update them yet, as we'll probably do so anyway at some point. Also, I think
we might want to introduce a common/data/licenses instead for those.
* If you encounter any problems, please tell!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29876 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7e5ffaa2 01-Apr-2009 Axel Dörfler <axeld@pinc-software.de>

* Now accepts only the first character that is dropped on a key.
* Also, escaped strings (like those from CharacterMap) are now converted
automatically.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29851 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 751c91b7 31-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* Added Keymap::operator=().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29824 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ebe98045 30-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* Added ability to change modifier keys (per drag and drop).
* Added button to switch shortcut modifier keys.
* Added option to make the KeyboardLayoutView non-editable.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29801 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0a39e396 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* Add capability to load other keyboard layouts from disk. It even works :-)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29714 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a869d32e 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* The L-shaped "enter" key can now also be drawn almost right (uses
BControlLook plus some clipping to do its magic).
* Fixed scancode only mode of the keyboard layout view.
* Fixed filter thanks to Rene.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29712 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 495c8b84 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* Cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29705 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 53f936a0 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* The Keymap now has a listener mechanism for changes.
* If the current Keymap is changed, the selection and use/revert buttons now
actually work.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29700 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6b9767aa 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* The text control is now back - instead of overwriting BTextView::KeyDown(),
we now use a plain BTextControl, and a custom message filter. For some reason,
BHandler::AddFilter() does not work, though, this needs some investigation.
* Enabled the font menu again, the font in the text control is changed as well.
* Made the default window size a bit smaller on large screens.
* Scrolling to the selection does not seem to work before Show() - looks like
a bug in the layout implementation.
* Moved some methods around to match their declaration order.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29698 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e4aad26f 24-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* While the new stuff isn't really ready for prime time, I've switched over
to it now (also to get some comments). It already looks better than the old
one, at least.
* The KeymapWindow is now using our layout engine.
* Removed the old MapView.
* Do you think the text view is necessary? And the ability to switch the font?
(I've removed both for now, comments welcome)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29684 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9d7d4a74 09-Feb-2009 Jérôme Duval <korli@users.berlios.de>

reverted r29176. it's not OK with shutdown and it could also be a bug in interface kit.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29178 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c8530759 09-Feb-2009 Jérôme Duval <korli@users.berlios.de>

fix #3414. Quits when the window is active.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29176 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 97893f16 24-Oct-2008 Alexandre Deckner <alex@zappotek.com>

* Removed the enclosing box to gain some space and enlarged the listviews. Should be
rethought and reimplemented with the layout system and my keymap management patch, but
the intent was to make it more usable in the mean time.
* Don't change the focus on keydown so that we can naviguate the list with the
keyboard.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28314 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7a249e96 24-Oct-2008 Alexandre Deckner <alex@zappotek.com>

Few fixes to the keymap preflet to make it good enough for the alpha 1. Lots of
things could be rewritten in a cleaner way but i'd rather finish my keymap
management patch as i rewrote the preflet for it anyway. For example the '(Current)'
item shouldn't be needed anymore but is still there in case the keymap:name attribute
read fails or if the original keymap file doesn't exist anymore (for example, applying
a user keymap, quiting the preflet, deleting the keymap file, and reloading the
preflet)

* Revert/apply data wasn't correctly loaded when the first load was on a system
keymap. This would allow revert/apply right after starting the preflet. That was the
cause of #2659.
* fCurrentMapName wasn't updated after a Revert or Apply
* Select the active keymap in the lists after reverting.

Quick cosmetical fix follows.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28313 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d556a216 24-Sep-2008 Stefano Ceccherini <stefano.ceccherini@gmail.com>

delete the str array in any case, although if numBytes <= 0, the array woulnd't have been allocated. CID 882.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27736 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 657a3676 25-Sep-2008 Stefano Ceccherini <stefano.ceccherini@gmail.com>

don't leak the BMessenger. CID 884

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27731 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c9e62886 23-Sep-2008 Stefano Ceccherini <stefano.ceccherini@gmail.com>

Fixed every (hopefully) CID cases of delete where delete[] should have been used. CID 122, 123, 124, 125, 126, 127, 128, 129, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 142, 143, 144, 147, 148, 149, 150

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27703 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 31c5eb6a 16-Sep-2008 Jérôme Duval <korli@users.berlios.de>

clean up


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27588 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b735dc91 26-Apr-2008 Jérôme Duval <korli@users.berlios.de>

I don't remember why this was added. Fixes bug #2165


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25178 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9c6ab2ae 12-Apr-2008 Jérôme Duval <korli@users.berlios.de>

fixed bug #2067


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24938 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 487171f0 11-Apr-2008 Rene Gollent <anevilyak@gmail.com>

Keymap preferences now saves an attribute on the Key_map file to indicate
what keymap it came from. This allows us to indicate the current keymap in
the list views. I'm not sure how to get the build system to populate that
attribute by default though.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24924 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 793fb95c 29-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* not a "chef d'oeuvre" but revert and apply buttons should behave as
expected now
* removed some dead code


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24180 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 988e5c55 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* set the view color after calling BControl::AttachedToWindow since it
overrides it, thanks Axel!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24132 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c80d10ee 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* fixed background flickering
* removed dead code (doesn't use pulse anymore)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24119 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 877c1bc7 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* more style cleanup


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24116 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ad93c2f5 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* style cleanup, new style casts, license header updates


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24113 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c8f93d18 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* rewrote drawing to use an offscreen view
* made keys move down when pressed
* reduced font size of locks light's text to fit in

This fixes #251, style cleanup will follow


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24110 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 644c8456 18-Feb-2008 Alexandre Deckner <alex@zappotek.com>

- fixes the Keymap preflet instead, as suggested by korli.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24015 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 269fdeef 13-Jan-2008 Jérôme Duval <korli@users.berlios.de>

style cleanup
whitespace => tab


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23505 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 37c77046 08-Aug-2006 DarkWyrm <darkwyrm@gmail.com>

Added a quick hack to mitigate font sensitivity problems until it can be handled properly


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18463 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 99e002f3 04-Jun-2006 Jérôme Duval <korli@users.berlios.de>

avoids drawing unknown keys


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17719 a95241bf-73f2-0310-859d-f6bbb57e9c96


# faccea39 22-Aug-2005 Jérôme Duval <korli@users.berlios.de>

we check GetHasGlyphs for deadkeys characters too


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14055 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a2618d1f 23-Aug-2005 Jérôme Duval <korli@users.berlios.de>

clean up


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14052 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b1e1fbae 20-Jul-2005 Jérôme Duval <korli@users.berlios.de>

replaced UBYT with B_UINT8_TYPE


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13781 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a10cf76e 24-Jun-2005 Axel Dörfler <axeld@pinc-software.de>

Renamed src/prefs to "preferences", as the directory is usually called in BeOS.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13263 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 881325a06eabaed95c4cf6450b2895f8284accba 14-Sep-2015 Axel Dörfler <axeld@pinc-software.de>

Keymap: improve initial window size, and position.

* By making it scale with the font size, and by using
BWindow::MoveOnScreen().


# b433c2ad87ce85265ca5674be338f3716372a512 07-Jan-2015 John Scipione <jscipione@gmail.com>

Keymap: Add ability to remove a key mapping

... of a normal (non-modifier) key via a right click menu.


# 5e96d7d537fbec23bad4ae9b4c8e7b02e769f0c6 21-Feb-2014 John Scipione <jscipione@gmail.com>

Localize keyboard layout names in Keymap preferences


# 374cf8c85db8415c3915f83a8b4c700ee2f37676 13-May-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Localize keymap names in Keymap preferences


# a073305c9669e9a76db294148e6eef1e5ceb2d5e 19-Feb-2014 John Scipione <jscipione@gmail.com>

keymap: limit set of left/right swap options

For Shift, Control, Option, and Command assume that you want to shift
on the same side, left-for-left, right-for-right. The Menu key is
available on either the left or right side, and lock keys can be
swapped with any other modifier left or right.

If we have multiple unmapped modifiers we need to do a little extra
work to figure out which of the unmapped modifiers to swap with.

Convert private class member methods to static functions.

Also update copyright info


# 8eb27eaa797ad24b843fca7c4047f0709eeb49af 04-Sep-2013 John Scipione <jscipione@gmail.com>

Keymap: Allow you to unset modifier keys

Selecting the marked menu item will unset the mapping for that modifier.

We can't rely on there being a unique mapping for a key (more than one
could be set to 0 aka unset) so we have to set the menu item names based
on the interface defs constants intead.


# c959ce461234be679b438b86cc854c0d8f1889db 12-May-2013 John Scipione <jscipione@gmail.com>

Some small style fixes


# 173b5a686d834bb354bce8e1ac00e587d0ede4c2 10-May-2013 John Scipione <jscipione@gmail.com>

Keymap: swap modifiers keys via context menu

When the user right clicks on a modifier key pop up a menu listing the
available modifiers. When the user selects a modifier from the menu swap
the key with the selected modifier. This provides an alternative way to swap
modifier keys other than drag&drop that works for just modifier keys.


# f6c5dbf81cf723abdbdae12fc4ec81c780ed2190 03-Jan-2014 Humdinger <humdingerb@gmail.com>

Some more code style corrections of Keymap.


# 346c9923524a469505f5b4b1cb9f29cadcdeee1d 03-Jan-2014 Humdinger <humdingerb@gmail.com>

Cleanup of KeymapWindow.cpp


# 803fab4facf1bb7222728f33d8b820388dacd0ff 02-Jan-2014 Humdinger <humdingerb@gmail.com>

Slightly improved layout of Keymap prefs

* use the templated BLayoutBuilder
* reduced top inset to be the same as to all sides
* SetExplicitMinSize of the LayoutView so it can't shrink to
illegibility
* set slightly smaller window default size (on small screens)


# c93efdb37f5e4f9c25ed0f81bfab1063e02b1132 10-Nov-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Keymap preflet: Sort the lists


# 38fa81bf8f0ccc37a615a9f5bd333f9b781322b3 03-Oct-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Remove B_COMMON*_DIRECTORY and kCommon*Directory constants

* This does intentionally break source compatibility, so that a review
of concerned code is forced.
* Binary compatibility should be maintained in most cases. The values
of the constants for the writable directories are now used for the
writable system directories. The values for the non-writable
directories are mapped to "/boot/system/data/empty/...", an empty or
non-existent directory, so that they will simply be skipped in search
paths. Only code that explicitly expects to find something in a
B_COMMON_* directory, will fail.


# 7889cac6cf4c8b7b8378356eec3ab30a70650794 12-May-2013 John Scipione <jscipione@gmail.com>

Keymap: Add Defaults button to revert keymap

Fixes #9980

Since hrev44455 we save your modifier keys settings when you switch
keymaps so you could get your modifiers keys messed up and unable to
get back to normal. This Defaults button allows you to override all
that and go back to the default US-International keymap with default
modifiers so you can start with a fresh slate and set things up the
way you want.

Also moved Revert button to the left side next to the Defaults button.
We do this on other preflets, the right side is reserved for an Apply
or OK button, and, if the preflet doesn't have one, is left empty.


# 546208a53940a26c6379c48a7854ade1a8250fc5 16-Apr-2012 Oliver Tappe <zooey@hirschkaefer.de>

More catalog-related cleanup.

* rename B_TRANSLATE_CONTEXT to B_TRANSLATION_CONTEXT and
B_TRANSLATE_WITH_CONTEXT to B_TRANSLATE_CONTEXT, squashing a TODO
* adjust all uses of both macros in Haiku's source tree
* use correct header guard for collecting/Catalog.h

The renamed macros require adjustments to all external applications
using catalogs.


# 3cee15aac2ef8c6ae8975d9add34c36aa4224c29 28-Mar-2012 John Scipione <jscipione@gmail.com>

Keymap changes from recent activity. No AltGr yet.

Below is a mostly complete summary of the changes in this commit.

* Set the DeadKeys for the US-International Keymap to use the Option map.
* Rename American keymap to US
* Update the US, US-International, and United-Kingdom keymaps to take
out unneeded spaces in the option layer. Also updated the dead keys
and some other keys on the US-International keyboard to use UTF-8
characters rather than there ASCII equivalents when different.
* Make the Option key fall-through when there is no mapping in the Option
table. Option is for special characters, if none, print the regular one.
This is mostly meant for the US keymap which has an empty option map. But
also so that you don't have to repeat the normal, shift, and caps maps in
the option map needlessly. Although the keymaps are still not empty in
some cases that it could be like numpad keys and space.
* Update the /bin/keymap app to use fputs() instead of printf() when there
is no actual formatting taking place. I've gotten into trouble for doing
this before and it is faster to not process the string unnecessarily.
* Also several 80-char limit style fixes and updated comments.
* In Keymap class Reorder the modifier keys to match the keymap files.
Put B_CONTROL_KEY check above B_OPTION_KEY. Neither change has any effect,
they are purely aesthetic.
* Update DumpKeymap() method to use the abbreviated modifier letters so it
will fit in your 80-char wide terminal.
* Tiny style fix in InputServer
* 80-char limit style fix in BWindow and add a comment that the shortcut
gets eaten in the case of Cmd+Q
* Implement IndexForModifier() in KeyboardLayout, although I am not using it.
* Take Caps Lock out of the Modifier keys window because I couldn't get
it to work the way I wanted it to.
* Move key roles to the left column, and the key label on the left. Add column
header labels. Thanks Rimas!
* Add validation and improve marking menu options. Add a 'Disabled' option
to control, option, and command menus to disable the key. Make the key
role text grey if the key roles is disabled. Validation ensures that you
cannot repeat the same key twice in the Modifier keys window since that
won't work. You can't define 2 sets of option keys even if you really want
to. You can disable your control, option, and command keys if you
want, but that is not recommended.
* Rename kUpdateModifiers to kUpdateModifierKeys message to differetiate
it from kUpdateModifier.
* Add shift key to Modifier keys window, use the stop icon instead of the
warning icon to indicate conflicts.
* Allow the Layout system to control the size of the Modifier keys window
again, set the width's of the key role lables to the widest, set the width
of the menu fields to take up the rest of the space minus room for the
conflict views. I didn't like it that the Modifier keys window would change
size based on what options you had selected in the menu fields. Now it
doesn't, but, the layout system still makes it all fit.


# 1a6b60e613fde4ec77dd3bb247987e3430703c6f 25-Mar-2012 John Scipione <jscipione@gmail.com>

Addresses some of the issues brought up in ticket #8148

The key labels have been changed to Win/Option and Alt/Command
to better associate them with the key names on a PC keyboard. This is
not perfect, but, better.

Added a checkbox entitled "Switch right Alt/Command and Win/Option keys"
This checkbox does what it says, switches the keys on the right side
of your keyboard leaving the left side according to how you set them.
This is needed for some international keymaps.

Whether or not you have switched already is not remembered, you have to
check the box each time you open the dialog. I don't know how to figure
out whether or not the keys have been switched already reliably. Hopefully
this isn't a big deal.

Set the menu option and window title to sentence case, thanks Humdinger.


# bce949f5318afe7645b643274f9d48c5ed8fa1cc 07-Nov-2011 John Scipione <jscipione@gmail.com>

Implemented the style changes and other improvements suggested by Axel to the Keymap preference app Modifier Keys window. The number of lines of code in the class was significantly reduced by these changes. I also made one small change to change the window title from 'Modifers Keys' to 'Modifier Keys'.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43221 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f5ac2da0a80a5c1075cfb06747c58a5f95ea124a 07-Nov-2011 John Scipione <jscipione@gmail.com>

Adds a dialog to the Keymap preference app to more easily and
reliably change your modifier keys.

The dialog box is shown by selecting the new 'Set Modifier Keys...'
option under the File menu. This brings up a window which contains 4
dialog boxes labeled: Caps Lock, Control, Option, and Command.

Each of the labels in followed by a drop down box which allows you to select
from one of the other keys listed. So for instance you could switch the Caps
Lock and Control keys but selecting the 'Control' option next to Caps Lock and
the 'Caps Lock' option next to Control.

The Caps Lock menu has an additional option which I find appealing...
'Disable' which, as it sounds, disables your Caps Lock key.

At the bottom of the dialog there are 3 buttons, 'Cancel', 'Revert', and 'Ok'.
'Cancel' and 'Ok' are self explanatory. The 'Revert' button, which is
initially disabled, puts you back into the state that you were when you first
opened the dialog.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43210 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 08cd4bc208c658ee17b0825529d5e8479d4fd560 01-Nov-2011 John Scipione <jscipione@gmail.com>

Add 3 new Apple Aluminum keyboard layout files and update and rename the
existing 'Apple Aluminium' keyboard layout to 'Apple Aluminium Extended
International.' The 3 new layout files are US mini and extended version
as well as an international mini version. This completes #7964

International corresponds to keyboard layouts for all locales except the US
and Japan. I have Japanese Apple Aluminum keyboard layout files almost
ready but I first need to determine what the special kana and eisu keys
are mapped to.

The Apple Aluminum keyboard layout files are tucked away in an Apple Aluminum
subdirectory. The Keymap preference app has been modified to turn
subdirectories into submenus of the Layout menu.

HaikuImage has been modified to include each keyboard layout file in the
image individually as recommended by Ingo.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43093 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 560ff4478d5c85455ea3e5ed5e392ef93132d545 25-Mar-2011 Jonas Sundström <jonas@kirilla.com>

Use resource definition files instead of DoCatalogs rule. Rename B_TRANSLATE_APP_NAME and related macros to the more generic B_TRANSLATE_SYSTEM_NAME, to also fits add-ons, folders, etc, and make 'System name' its standard context. Change CodyCam and PoorMan's app signatures to match the overall x-vnd.Haiku-App pattern. Some clean-up. Make SlideShowSaver build again.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41103 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d374a27286b8a52974a97dba0d5966ea026a665d 16-Mar-2011 Jonas Sundström <jonas@kirilla.com>

App name localization.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40980 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8f62243f372b69918512816a43173b5456c764b9 17-Aug-2010 Oliver Tappe <zooey@hirschkaefer.de>

* fix warnings in Keymap preflet about hidden virtual by renaming SetFont()
to SetBaseFont() (and fFont to fBaseFont)
* enabled -Werror for all preflets


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38203 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1fd91b7ffd48e2b21ab98e3865ff94201ac59544 17-Aug-2010 Alex Wilson <yourpalal2@gmail.com>

Small compilation fixes for coming layout changes... (really!!)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38202 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4eb0cbb044cf538f18c0d252934a5bcaa33bfd34 07-May-2010 Matt Madia <mattmadia@gmail.com>

Updated TR_CONTEXT to be B_TRANSLATE_CONTEXT, relating to #5408.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36733 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3d7bf37bf3b557139c267d03276026258d061da8 06-May-2010 Matt Madia <mattmadia@gmail.com>

Updated to use B_TRANSLATE* macros. relates to #5408.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36687 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b44c25de42ce39022f701d5637797b2f57e63679 16-Apr-2010 Axel Dörfler <axeld@pinc-software.de>

* Factored out a single base class out of the three Keymap implementations we
had in our tree.
* Adapted Keymap, <input>keyboard, and consoled to use it - the additional
functionality is implemented via a subclass in the first two cases.
* "keymap" will come next.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36328 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0b2fbbfaa9d35d304991f3543276c8e46f155460 24-Dec-2009 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

Patch by Humdinger to convert all the preference panels to sentance case.
Also update the localization catalogs as needed.
CPUFrequency localization is broken : the current code works, but the DoCatalogs jamrule is not powerful enough to properly extract the catkeys.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34767 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9c1a9b926aa0b1890a011a44398379d1c47f09c1 20-Dec-2009 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

* Patch by Humdinger to convert a lot of things to sentance case.
* Cleanup and update of all the touched catkeys files


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34731 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b10da4d8c70ed3a971c58415437bf79d88ee8155 27-Oct-2009 Axel Dörfler <axeld@pinc-software.de>

* _UpdateButtons() was called too early, before fCurrentMap, and fAppliedMap
were initialized, causing Keymap to lose the current map.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33808 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ad34440edce9f5d4e604a9a2b0a3116e1dd74fde 27-Oct-2009 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

-Removed unseless reference to adler32 in hashmapcatalog
-Localized Keymap preflet and translated it to french


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33790 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b01bdb48ea5093f6c20b58540f9a326d452cbc17 17-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* The Keymap preferences app will now memorize its window frame and chosen
layout.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32491 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c5bf61690ac689071136bbac1475635f4c007857 17-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* When switching modifiers, the source key was not invalidated, making it appear
as if a copy happened. This closes bug #4242.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32490 a95241bf-73f2-0310-859d-f6bbb57e9c96


# aa0f32cfbd81659c01209ada37d0148cdd34727d 12-May-2009 Oliver Tappe <zooey@hirschkaefer.de>

* removed KeymapMessageFilter, as it is no longer needed
* fixed a couple of issues with respect to internal/external naming of
keymaps and the respective files, hopefully such that there's always one
keymap active in the view: either one that has been selected or (Current)
if any changes have been applied
* replaced the dead-key-menubar with a menufield (thanks Axel, looking much
better)
cleanup:
* removed remnants of Use-button (message constant and switch-case)
* dropped 'Save' menu item, as it wasn't implemented anyway and would now
never be enabled
* removed fFirstTime, as it caused problems, but did not serve any purpose
anymore


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30734 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6be10e281f6e162f8b4008c6003ef4d81dbbd8de 12-May-2009 Oliver Tappe <zooey@hirschkaefer.de>

* Removed the 'Use' button from the keymap preflet, since several people have
mentioned that they tend to forget pressing it (including me, of course), in
effect losing all changes.
The way the code currently works, having it didn't really make sense IMO,
as any change will only ever be applied to the "current" keymap. If you want
to keep your keymap more persistently, you need to save it into a named file,
anyway.
Please give it a try and shout if this is unacceptable.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30723 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 83936c1c26990457a3de22f0df6d8fa005e24026 12-May-2009 Oliver Tappe <zooey@hirschkaefer.de>

* Added support for selecting the dead key trigger characters from a menubar,
offering two choices for acute and diaeresis as well as allowing to switch
off each dead key completely.
* moved the textview on a line of its own such that the dead key menu and
the modifier-switching button live together on one line
* added enum dead_key_index and used it at a couple of places instead of
having to use the magic numbers 1-5
* refactored the actual updating of the fChars buffer from SetKey() into
_SetChars(), which is now being invoked by SetDeadKeyTrigger(), too

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30718 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1e855c376c4f785f926c0c4d4d08c827c05da643 12-Apr-2009 Ingo Weinhold <ingo_weinhold@gmx.de>

* Patch by Fredrik Ekdahl: gcc 4 build fixes (missing headers).
* Added missing header for mountvolume.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30135 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6db2be327d3e4a3bd16095ff8a6fc147af326794 05-Apr-2009 Axel Dörfler <axeld@pinc-software.de>

* Changed the way the shortcuts are switched: we no longer do the same thing
as BeOS on the right side (that is, switching control and option key), but
switch control and command there as well.
* As a consequence, the Alt-Gr key will stay where it is when switching the
shortcuts.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29929 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 317bd7dda3eb26d4d24ba5b0a831461119f70d34 03-Apr-2009 Axel Dörfler <axeld@pinc-software.de>

* Changed directory structure as suggested on the mailing list.
* Made the TimeZoneView less error prone, and also actually use Haiku code (the
previous check didn't work since it used #if, not #ifdef).
* Also took the liberty to rename our boot loader to haiku_loader, since I had
to update the nasm binary anyway. Updated the assembly sources to nasm 2.0.
* I haven't found where the synth location in the MIDI code is specified,
though.
* Also, NetBootArchive, and FloppyBootImage haven't been updated yet. Will do
so next.
* Some optional packages still put their license to beos/etc/licenses. I didn't
update them yet, as we'll probably do so anyway at some point. Also, I think
we might want to introduce a common/data/licenses instead for those.
* If you encounter any problems, please tell!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29876 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7e5ffaa2233770c4bc45cfd729689bfe4e1d5051 01-Apr-2009 Axel Dörfler <axeld@pinc-software.de>

* Now accepts only the first character that is dropped on a key.
* Also, escaped strings (like those from CharacterMap) are now converted
automatically.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29851 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 751c91b7e12e7be15849d53c0774aa96cfb2d598 31-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* Added Keymap::operator=().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29824 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ebe98045d7383cee5d80c918eb5667b7b9106181 30-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* Added ability to change modifier keys (per drag and drop).
* Added button to switch shortcut modifier keys.
* Added option to make the KeyboardLayoutView non-editable.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29801 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0a39e396165111d63ef438482bf60125a3903663 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* Add capability to load other keyboard layouts from disk. It even works :-)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29714 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a869d32e0c005b398bc43a8c1078fd2d49dc2a9d 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* The L-shaped "enter" key can now also be drawn almost right (uses
BControlLook plus some clipping to do its magic).
* Fixed scancode only mode of the keyboard layout view.
* Fixed filter thanks to Rene.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29712 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 495c8b848bfd606462331318b1f4c2b7b8d0409d 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* Cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29705 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 53f936a0a7bab0496eefc0679e4f13c8a58ca308 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* The Keymap now has a listener mechanism for changes.
* If the current Keymap is changed, the selection and use/revert buttons now
actually work.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29700 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6b9767aa8adacafb63700e4ec46478c812f46e9c 25-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* The text control is now back - instead of overwriting BTextView::KeyDown(),
we now use a plain BTextControl, and a custom message filter. For some reason,
BHandler::AddFilter() does not work, though, this needs some investigation.
* Enabled the font menu again, the font in the text control is changed as well.
* Made the default window size a bit smaller on large screens.
* Scrolling to the selection does not seem to work before Show() - looks like
a bug in the layout implementation.
* Moved some methods around to match their declaration order.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29698 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e4aad26fec2e5ff3e807e54c88892592198ce29e 24-Mar-2009 Axel Dörfler <axeld@pinc-software.de>

* While the new stuff isn't really ready for prime time, I've switched over
to it now (also to get some comments). It already looks better than the old
one, at least.
* The KeymapWindow is now using our layout engine.
* Removed the old MapView.
* Do you think the text view is necessary? And the ability to switch the font?
(I've removed both for now, comments welcome)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29684 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9d7d4a74b5314ec84a968b18993a1054e9bacb28 09-Feb-2009 Jérôme Duval <korli@users.berlios.de>

reverted r29176. it's not OK with shutdown and it could also be a bug in interface kit.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29178 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c8530759dd14cc6a0777493ad5462995b9bdd021 09-Feb-2009 Jérôme Duval <korli@users.berlios.de>

fix #3414. Quits when the window is active.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29176 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 97893f16afc2c2a75e50f7958545f3be2a24ec67 24-Oct-2008 Alexandre Deckner <alex@zappotek.com>

* Removed the enclosing box to gain some space and enlarged the listviews. Should be
rethought and reimplemented with the layout system and my keymap management patch, but
the intent was to make it more usable in the mean time.
* Don't change the focus on keydown so that we can naviguate the list with the
keyboard.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28314 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7a249e96f520c0570ea8e5b245cad027c33c9c91 24-Oct-2008 Alexandre Deckner <alex@zappotek.com>

Few fixes to the keymap preflet to make it good enough for the alpha 1. Lots of
things could be rewritten in a cleaner way but i'd rather finish my keymap
management patch as i rewrote the preflet for it anyway. For example the '(Current)'
item shouldn't be needed anymore but is still there in case the keymap:name attribute
read fails or if the original keymap file doesn't exist anymore (for example, applying
a user keymap, quiting the preflet, deleting the keymap file, and reloading the
preflet)

* Revert/apply data wasn't correctly loaded when the first load was on a system
keymap. This would allow revert/apply right after starting the preflet. That was the
cause of #2659.
* fCurrentMapName wasn't updated after a Revert or Apply
* Select the active keymap in the lists after reverting.

Quick cosmetical fix follows.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28313 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d556a216cf8b6941a3c4cbd1b949732dc90be8ff 24-Sep-2008 Stefano Ceccherini <stefano.ceccherini@gmail.com>

delete the str array in any case, although if numBytes <= 0, the array woulnd't have been allocated. CID 882.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27736 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 657a3676f9932d3395897db617a4e295a284ffc6 25-Sep-2008 Stefano Ceccherini <stefano.ceccherini@gmail.com>

don't leak the BMessenger. CID 884

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27731 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c9e6288649ba36ff887f52fb62d4cd557fa9ef34 23-Sep-2008 Stefano Ceccherini <stefano.ceccherini@gmail.com>

Fixed every (hopefully) CID cases of delete where delete[] should have been used. CID 122, 123, 124, 125, 126, 127, 128, 129, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 142, 143, 144, 147, 148, 149, 150

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27703 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 31c5eb6ad7a743106552b82555aaf2241e8c034f 16-Sep-2008 Jérôme Duval <korli@users.berlios.de>

clean up


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27588 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b735dc91eb31153a8a16664a59eab9d1b29879e8 26-Apr-2008 Jérôme Duval <korli@users.berlios.de>

I don't remember why this was added. Fixes bug #2165


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25178 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9c6ab2ae368b10bb00de7f8682c7b34931a5011a 12-Apr-2008 Jérôme Duval <korli@users.berlios.de>

fixed bug #2067


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24938 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 487171f0b915ae973e4b8bb80cb8c989e48e543e 11-Apr-2008 Rene Gollent <anevilyak@gmail.com>

Keymap preferences now saves an attribute on the Key_map file to indicate
what keymap it came from. This allows us to indicate the current keymap in
the list views. I'm not sure how to get the build system to populate that
attribute by default though.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24924 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 793fb95c82d4325c5df176fc407d3234f96daf59 29-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* not a "chef d'oeuvre" but revert and apply buttons should behave as
expected now
* removed some dead code


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24180 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 988e5c553f68c20d6f19d35435a137f36e29f475 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* set the view color after calling BControl::AttachedToWindow since it
overrides it, thanks Axel!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24132 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c80d10ee356fb3745b13300148d184d73489d836 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* fixed background flickering
* removed dead code (doesn't use pulse anymore)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24119 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 877c1bc7fb85a3439f3627303574288f1a18f039 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* more style cleanup


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24116 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ad93c2f5ebcde6ff4a231ebd422dee2773c8f502 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* style cleanup, new style casts, license header updates


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24113 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c8f93d1843dff7e15261d8fc08d0199c65225c21 25-Feb-2008 Alexandre Deckner <alex@zappotek.com>

* rewrote drawing to use an offscreen view
* made keys move down when pressed
* reduced font size of locks light's text to fit in

This fixes #251, style cleanup will follow


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24110 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 644c84564ab710ffc79e272a0206442edeff01e5 18-Feb-2008 Alexandre Deckner <alex@zappotek.com>

- fixes the Keymap preflet instead, as suggested by korli.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24015 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 269fdeefff71dbb13136f7404d612ed2e4284131 13-Jan-2008 Jérôme Duval <korli@users.berlios.de>

style cleanup
whitespace => tab


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23505 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 37c77046c2681a22f72fa01cab980f454b97ff42 08-Aug-2006 DarkWyrm <darkwyrm@gmail.com>

Added a quick hack to mitigate font sensitivity problems until it can be handled properly


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18463 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 99e002f375a87af4173c5d582d37711f5fe5362a 04-Jun-2006 Jérôme Duval <korli@users.berlios.de>

avoids drawing unknown keys


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17719 a95241bf-73f2-0310-859d-f6bbb57e9c96


# faccea39113ceffaf741e01eb4d8c7099cccc3bf 22-Aug-2005 Jérôme Duval <korli@users.berlios.de>

we check GetHasGlyphs for deadkeys characters too


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14055 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a2618d1f2218bf54e257ec947440a81a8b0bc113 23-Aug-2005 Jérôme Duval <korli@users.berlios.de>

clean up


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14052 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b1e1fbaedaf1ab199a6ed4234fb332c27aa2bfd3 20-Jul-2005 Jérôme Duval <korli@users.berlios.de>

replaced UBYT with B_UINT8_TYPE


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13781 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a10cf76ef5b9e8c726ebc47183abd6943023cf8f 24-Jun-2005 Axel Dörfler <axeld@pinc-software.de>

Renamed src/prefs to "preferences", as the directory is usually called in BeOS.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13263 a95241bf-73f2-0310-859d-f6bbb57e9c96