virtualkeyboard: code style fixes
This commit is contained in:
committed by
François Revol
parent
b8fe0b588d
commit
67b3c67768
@@ -87,11 +87,6 @@ private:
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
KeyboardLayoutView::KeyboardLayoutView(const char* name,
|
KeyboardLayoutView::KeyboardLayoutView(const char* name,
|
||||||
BInputServerDevice* dev)
|
BInputServerDevice* dev)
|
||||||
:
|
:
|
||||||
|
|||||||
@@ -123,7 +123,6 @@ private:
|
|||||||
float fGap;
|
float fGap;
|
||||||
|
|
||||||
BInputServerDevice* fDevice;
|
BInputServerDevice* fDevice;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ print_key(char *chars, int32 offset, bool last = false)
|
|||||||
default:
|
default:
|
||||||
{
|
{
|
||||||
// 2-, 3-, or 4-byte UTF-8 character
|
// 2-, 3-, or 4-byte UTF-8 character
|
||||||
char *str = new char[size + 1];
|
char* str = new char[size + 1];
|
||||||
strncpy(str, &chars[offset], size);
|
strncpy(str, &chars[offset], size);
|
||||||
str[size] = 0;
|
str[size] = 0;
|
||||||
fputs(str, stdout);
|
fputs(str, stdout);
|
||||||
|
|||||||
@@ -2,8 +2,8 @@
|
|||||||
* Copyright 2014 Freeman Lou <[email protected]>
|
* Copyright 2014 Freeman Lou <[email protected]>
|
||||||
* All rights reserved. Distributed under the terms of the MIT license.
|
* All rights reserved. Distributed under the terms of the MIT license.
|
||||||
*/
|
*/
|
||||||
#ifndef VKID_H
|
#ifndef VIRTUAL_KEYBOARD_INPUT_DEVICE_H
|
||||||
#define VKID_H
|
#define VIRTUAL_KEYBOARD_INPUT_DEVICE_H
|
||||||
|
|
||||||
|
|
||||||
#include <InputServerDevice.h>
|
#include <InputServerDevice.h>
|
||||||
@@ -28,4 +28,4 @@ private:
|
|||||||
|
|
||||||
extern "C" BInputServerDevice* instantiate_input_device();
|
extern "C" BInputServerDevice* instantiate_input_device();
|
||||||
|
|
||||||
#endif // VKID_H
|
#endif // VIRTUAL_KEYBOARD_INPUT_DEVICE_H
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
#include "KeyboardLayoutView.h"
|
#include "KeyboardLayoutView.h"
|
||||||
#include "KeymapListItem.h"
|
#include "KeymapListItem.h"
|
||||||
|
|
||||||
static const uint32 kMsgMenuFontChange = 'MMFC';
|
static const uint32 kMsgMenuFontChange = 'mMFC';
|
||||||
|
|
||||||
static int
|
static int
|
||||||
compare_key_list_items(const void* a, const void* b)
|
compare_key_list_items(const void* a, const void* b)
|
||||||
@@ -40,8 +40,8 @@ VirtualKeyboardWindow::VirtualKeyboardWindow(BInputServerDevice* dev)
|
|||||||
BScreen screen;
|
BScreen screen;
|
||||||
BRect screenRect(screen.Frame());
|
BRect screenRect(screen.Frame());
|
||||||
|
|
||||||
ResizeTo(screenRect.Width(), screenRect.Height()/3);
|
ResizeTo(screenRect.Width(), screenRect.Height() / 3);
|
||||||
MoveTo(0,screenRect.Height()-screenRect.Height()/3);
|
MoveTo(0,screenRect.Height() - screenRect.Height() / 3);
|
||||||
|
|
||||||
SetLayout(new BGroupLayout(B_VERTICAL));
|
SetLayout(new BGroupLayout(B_VERTICAL));
|
||||||
|
|
||||||
@@ -161,5 +161,5 @@ VirtualKeyboardWindow::_LoadFonts()
|
|||||||
void
|
void
|
||||||
VirtualKeyboardWindow::MessageReceived(BMessage* message)
|
VirtualKeyboardWindow::MessageReceived(BMessage* message)
|
||||||
{
|
{
|
||||||
|
BWindow::MessageReceived(message);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user