Beta version
Improvements are still possible git-svn-id: file:///srv/svn/repos/haiku/trunk/current@5650 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
bf757e6cca
commit
357ef4edac
@ -2,6 +2,10 @@ SubDir OBOS_TOP src prefs mouse ;
|
||||
|
||||
AddResources Mouse : Mouse.rsrc ;
|
||||
|
||||
Preference Mouse : Mouse.cpp MouseSettings.cpp MouseView.cpp MouseWindow.cpp ;
|
||||
Preference Mouse :
|
||||
Mouse.cpp
|
||||
MouseSettings.cpp
|
||||
MouseView.cpp
|
||||
MouseWindow.cpp ;
|
||||
|
||||
LinkSharedOSLibs Mouse : translation be root ;
|
||||
|
@ -1,18 +1,26 @@
|
||||
/*
|
||||
* Mouse.cpp
|
||||
* Mouse mccall@digitalparadise.co.uk
|
||||
*
|
||||
*/
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: Mouse.cpp
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created :
|
||||
// Modified : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
|
||||
#include <Alert.h>
|
||||
#include <Screen.h>
|
||||
|
||||
#include "Mouse.h"
|
||||
#include "MouseWindow.h"
|
||||
#include "MouseSettings.h"
|
||||
#include "MouseMessages.h"
|
||||
|
||||
const char MouseApplication::kMouseApplicationSig[] = "application/x-vnd.OpenBeOS-MOUS";
|
||||
const char kMouseApplicationSig[] = "application/x-vnd.OpenBeOS-MOUS";
|
||||
|
||||
int main(int, char**)
|
||||
{
|
||||
@ -24,65 +32,18 @@ int main(int, char**)
|
||||
}
|
||||
|
||||
MouseApplication::MouseApplication()
|
||||
:BApplication(kMouseApplicationSig)
|
||||
:BApplication(kMouseApplicationSig)
|
||||
{
|
||||
BRect rect(0, 0, 397, 293);
|
||||
MouseWindow *window = new MouseWindow(rect);
|
||||
window->MoveTo(window->fSettings.WindowCorner());
|
||||
|
||||
MouseWindow *window;
|
||||
|
||||
fSettings = new MouseSettings();
|
||||
|
||||
window = new MouseWindow();
|
||||
|
||||
window->Show();
|
||||
}
|
||||
|
||||
void
|
||||
MouseApplication::MessageReceived(BMessage *message)
|
||||
{
|
||||
switch(message->what) {
|
||||
case ERROR_DETECTED:
|
||||
{
|
||||
BAlert *errorAlert = new BAlert("Error", "Something has gone wrong!","OK",NULL,NULL,B_WIDTH_AS_USUAL, B_OFFSET_SPACING, B_WARNING_ALERT);
|
||||
errorAlert->Go();
|
||||
be_app->PostMessage(B_QUIT_REQUESTED);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
BApplication::MessageReceived(message);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
MouseApplication::SetWindowCorner(BPoint corner)
|
||||
{
|
||||
fSettings->SetWindowCorner(corner);
|
||||
}
|
||||
|
||||
void
|
||||
MouseApplication::SetMouseType(mouse_type type)
|
||||
{
|
||||
fSettings->SetMouseType(type);
|
||||
}
|
||||
|
||||
void
|
||||
MouseApplication::SetClickSpeed(bigtime_t click_speed)
|
||||
{
|
||||
fSettings->SetClickSpeed(click_speed);
|
||||
}
|
||||
|
||||
void
|
||||
MouseApplication::SetMouseSpeed(int32 speed)
|
||||
{
|
||||
fSettings->SetMouseSpeed(speed);
|
||||
}
|
||||
|
||||
void
|
||||
MouseApplication::AboutRequested(void)
|
||||
{
|
||||
(new BAlert("about", "...by Andrew Edward McCall", "Dig Deal"))->Go();
|
||||
}
|
||||
|
||||
MouseApplication::~MouseApplication()
|
||||
{
|
||||
delete fSettings;
|
||||
}
|
||||
|
@ -1,35 +1,31 @@
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: Mouse.h
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created :
|
||||
// Modified : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
|
||||
#ifndef MOUSE_H
|
||||
#define MOUSE_H
|
||||
|
||||
#include <Application.h>
|
||||
|
||||
#include "MouseWindow.h"
|
||||
#include "MouseSettings.h"
|
||||
|
||||
class MouseApplication : public BApplication
|
||||
{
|
||||
public:
|
||||
MouseApplication();
|
||||
virtual ~MouseApplication();
|
||||
|
||||
void MessageReceived(BMessage *message);
|
||||
BPoint WindowCorner() const {return fSettings->WindowCorner(); }
|
||||
void SetWindowCorner(BPoint corner);
|
||||
int32 MouseType() const {return fSettings->MouseType(); }
|
||||
void SetMouseType(mouse_type type);
|
||||
bigtime_t ClickSpeed() const {return fSettings->ClickSpeed(); }
|
||||
void SetClickSpeed(bigtime_t click_speed);
|
||||
int32 MouseSpeed() const {return fSettings->MouseSpeed(); }
|
||||
void SetMouseSpeed(int32 speed);
|
||||
|
||||
void AboutRequested(void);
|
||||
|
||||
private:
|
||||
|
||||
static const char kMouseApplicationSig[];
|
||||
|
||||
MouseSettings *fSettings;
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
Binary file not shown.
441
src/prefs/mouse/MouseBitmap.h
Normal file
441
src/prefs/mouse/MouseBitmap.h
Normal file
@ -0,0 +1,441 @@
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: MouseBitmap.h
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
|
||||
const int32 kMouseWidth = 57;
|
||||
const int32 kMouseHeight = 86;
|
||||
const color_space kMouseColorSpace = B_CMAP8;
|
||||
|
||||
const unsigned char kMouseBits [] = {
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x0f,0x1b,0x1b,0x0b,0x17,0x17,0x1b,
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x3f,0x3f,0x3f,0x1b,0x1b,0x1b,0x1b,
|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0x19,0x19,0x17,0x17,0x18,0x17,
|
||||
0x17,0x15,0x15,0x13,0x12,0x11,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,
|
||||
0x1e,0x3f,0x1c,0x1c,0x1c,0x1c,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1c,0x1b,0x1c,
|
||||
0x1c,0x1b,0x1c,0x1b,0x1c,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1a,0x1b,0x1a,0x1a,
|
||||
0x19,0x1a,0x1a,0x1a,0x19,0x19,0x19,0x17,0x17,0x18,0x17,0x17,0x15,0x15,0x15,0x13,
|
||||
0x13,0x12,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,0x1e,0x3f,0x1c,0x1c,
|
||||
0x1c,0x1c,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1c,0x1b,0x1c,0x1c,0x1b,0x1b,0x1b,
|
||||
0x1b,0x1b,0x1b,0x1a,0x1b,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x19,0x19,0x19,0x19,
|
||||
0x19,0x19,0x17,0x17,0x18,0x17,0x17,0x15,0x15,0x15,0x15,0x13,0x12,0x11,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,0x1c,0x3f,0x1c,0x1c,0x1c,0x1c,0x1b,0x1b,
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1a,0x1b,
|
||||
0x1b,0x1a,0x1a,0x1a,0x1a,0x19,0x19,0x1a,0x19,0x19,0x19,0x19,0x19,0x17,0x17,0x17,
|
||||
0x18,0x17,0x17,0x17,0x15,0x15,0x15,0x12,0x13,0x11,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1d,0x1e,0x1e,0x1e,0x1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a,0x19,0x1a,0x19,0x19,0x19,0x19,0x19,0x19,0x17,0x18,0x17,0x17,0x17,0x17,
|
||||
0x17,0x16,0x15,0x15,0x15,0x13,0x13,0x12,0x12,0x11,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1d,0x1e,0x1e,0x1c,0x1c,0x1c,0x1b,0x1a,0x1b,0x1a,0x1a,0x1a,0x1a,0x1a,
|
||||
0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x19,0x1a,0x19,
|
||||
0x19,0x19,0x19,0x17,0x18,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x15,0x16,0x15,0x15,
|
||||
0x15,0x13,0x13,0x13,0x11,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1e,0x1d,
|
||||
0x1c,0x1c,0x1b,0x1b,0x1c,0x1b,0x1a,0x1b,0x19,0x1a,0x1a,0x19,0x1a,0x19,0x1a,0x19,
|
||||
0x1a,0x1a,0x1a,0x19,0x1a,0x1a,0x1a,0x1a,0x1a,0x19,0x19,0x19,0x19,0x19,0x19,0x19,
|
||||
0x18,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x17,0x15,0x15,0x15,0x15,0x14,0x12,0x12,
|
||||
0x11,0x11,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,0x1e,0x1c,0x1c,0x1b,
|
||||
0x1b,0x1a,0x1b,0x1a,0x1a,0x19,0x19,0x1a,0x19,0x19,0x19,0x19,0x19,0x1a,0x1a,0x1a,
|
||||
0x1a,0x1a,0x1a,0x19,0x19,0x1a,0x19,0x19,0x19,0x19,0x19,0x17,0x18,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x16,0x15,0x15,0x15,0x15,0x13,0x13,0x12,0x11,0x11,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,0x1c,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x15,0x16,0x15,0x15,0x15,0x16,0x15,0x15,0x15,
|
||||
0x15,0x15,0x15,0x15,0x15,0x15,0x12,0x11,0x11,0x11,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1d,0x17,0x17,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,
|
||||
0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,
|
||||
0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,
|
||||
0x0b,0x0b,0x10,0x10,0x11,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x17,0x0b,
|
||||
0x0b,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,
|
||||
0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,
|
||||
0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x0b,0x0b,
|
||||
0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x0b,0x0b,0x1e,0x1e,0x1d,0x1c,0x1b,
|
||||
0x1b,0x1a,0x1a,0x1a,0x1a,0x19,0x19,0x19,0x18,0x19,0x19,0x19,0x19,0x19,0x19,0x17,
|
||||
0x19,0x19,0x19,0x19,0x19,0x19,0x17,0x18,0x17,0x18,0x17,0x17,0x17,0x17,0x17,0x16,
|
||||
0x17,0x17,0x17,0x15,0x15,0x15,0x15,0x13,0x13,0x18,0x17,0x17,0x0b,0x0b,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x3f,0x1d,0x1c,0x1c,0x1b,0x1b,0x1a,0x1b,0x1a,0x1a,
|
||||
0x1a,0x19,0x1a,0x19,0x19,0x18,0x17,0x17,0x19,0x19,0x19,0x18,0x19,0x17,0x19,0x18,
|
||||
0x17,0x19,0x17,0x18,0x19,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x15,0x16,0x15,0x15,
|
||||
0x15,0x15,0x15,0x15,0x14,0x12,0x11,0x12,0x17,0x17,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1d,0x1e,0x1e,0x1c,0x1c,0x1b,0x1b,0x1b,0x1b,0x1a,0x19,0x1a,0x19,0x19,
|
||||
0x17,0x18,0x19,0x19,0x17,0x19,0x17,0x18,0x17,0x19,0x19,0x17,0x19,0x19,0x18,0x17,
|
||||
0x18,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x17,0x17,0x15,0x16,0x15,0x15,0x15,0x13,
|
||||
0x13,0x12,0x12,0x11,0x11,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,
|
||||
0x1e,0x1b,0x1b,0x1c,0x1a,0x1a,0x1a,0x1a,0x1a,0x19,0x19,0x19,0x19,0x17,0x18,0x19,
|
||||
0x17,0x17,0x18,0x19,0x17,0x17,0x18,0x17,0x19,0x18,0x19,0x17,0x17,0x18,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x16,0x15,0x15,0x15,0x15,0x15,0x13,0x12,0x12,0x11,0x11,
|
||||
0x11,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,0x1c,0x1c,0x1c,0x1b,
|
||||
0x1a,0x1a,0x1b,0x1a,0x19,0x19,0x19,0x19,0x17,0x18,0x17,0x18,0x17,0x17,0x18,0x17,
|
||||
0x17,0x18,0x17,0x18,0x17,0x17,0x18,0x17,0x17,0x17,0x18,0x17,0x17,0x17,0x15,0x16,
|
||||
0x15,0x15,0x15,0x15,0x15,0x15,0x14,0x12,0x13,0x13,0x12,0x11,0x11,0x10,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,0x1c,0x1c,0x1b,0x1b,0x1a,0x1a,0x1a,0x1a,
|
||||
0x19,0x19,0x19,0x19,0x17,0x18,0x17,0x18,0x17,0x17,0x18,0x17,0x17,0x17,0x18,0x17,
|
||||
0x18,0x17,0x17,0x17,0x17,0x18,0x17,0x17,0x17,0x15,0x17,0x15,0x15,0x16,0x15,0x15,
|
||||
0x15,0x13,0x13,0x13,0x12,0x12,0x11,0x10,0x11,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1c,0x1c,0x1c,0x1c,0x1b,0x1b,0x1a,0x1a,0x1a,0x19,0x1a,0x19,0x19,0x19,
|
||||
0x17,0x17,0x18,0x17,0x17,0x17,0x18,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x18,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x13,
|
||||
0x13,0x12,0x12,0x11,0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,
|
||||
0x1c,0x1c,0x1b,0x1b,0x1a,0x1b,0x1a,0x19,0x19,0x19,0x19,0x17,0x18,0x17,0x18,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x13,0x12,0x12,0x12,0x10,
|
||||
0x11,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1c,0x1c,0x1c,0x1b,0x1b,
|
||||
0x1a,0x1a,0x1a,0x1a,0x19,0x19,0x18,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x17,0x15,0x15,
|
||||
0x16,0x15,0x15,0x15,0x15,0x13,0x13,0x12,0x12,0x12,0x12,0x11,0x10,0x10,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,0x1c,0x1c,0x1b,0x1b,0x1a,0x1a,0x1a,0x1a,
|
||||
0x19,0x17,0x19,0x19,0x18,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x15,0x17,0x15,0x16,0x15,0x15,0x15,0x15,
|
||||
0x13,0x15,0x13,0x12,0x12,0x12,0x11,0x11,0x11,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1d,0x1c,0x1c,0x1b,0x1b,0x1a,0x1a,0x1a,0x1a,0x19,0x19,0x19,0x18,0x17,
|
||||
0x17,0x18,0x17,0x17,0x17,0x17,0x15,0x17,0x17,0x15,0x17,0x16,0x17,0x17,0x17,0x17,
|
||||
0x17,0x15,0x17,0x15,0x15,0x17,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x12,0x12,
|
||||
0x12,0x12,0x11,0x11,0x10,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,
|
||||
0x1b,0x1b,0x1b,0x1b,0x1a,0x1a,0x1a,0x19,0x17,0x18,0x17,0x19,0x18,0x17,0x17,0x17,
|
||||
0x17,0x17,0x15,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x15,0x17,
|
||||
0x17,0x16,0x15,0x15,0x15,0x15,0x15,0x14,0x15,0x13,0x13,0x13,0x12,0x12,0x11,0x10,
|
||||
0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1c,0x1c,0x1c,0x1b,0x1b,0x1b,
|
||||
0x1a,0x19,0x19,0x19,0x19,0x19,0x17,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x15,0x15,
|
||||
0x15,0x17,0x16,0x15,0x15,0x15,0x16,0x15,0x17,0x15,0x15,0x16,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x15,0x15,0x14,0x12,0x12,0x12,0x13,0x12,0x12,0x11,0x10,0x0f,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1e,0x1b,0x1b,0x1a,0x1b,0x1a,0x1a,0x19,0x19,
|
||||
0x17,0x18,0x17,0x18,0x17,0x17,0x17,0x17,0x15,0x17,0x17,0x15,0x16,0x15,0x15,0x15,
|
||||
0x16,0x17,0x15,0x17,0x15,0x15,0x16,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x13,0x15,
|
||||
0x13,0x13,0x12,0x12,0x12,0x12,0x11,0x11,0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1c,0x1d,0x1c,0x1b,0x1a,0x1a,0x1a,0x19,0x19,0x19,0x19,0x18,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x16,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x16,0x15,
|
||||
0x15,0x15,0x16,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x13,0x13,0x12,0x12,
|
||||
0x12,0x11,0x11,0x10,0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1c,
|
||||
0x1c,0x1b,0x1b,0x1a,0x1a,0x1a,0x19,0x19,0x18,0x17,0x17,0x18,0x17,0x17,0x15,0x17,
|
||||
0x17,0x15,0x16,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x13,0x13,0x13,0x12,0x12,0x11,0x11,0x11,0x10,
|
||||
0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1c,0x1c,0x1c,0x1b,0x1a,0x1a,
|
||||
0x19,0x19,0x19,0x19,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x15,0x16,0x15,0x15,0x15,
|
||||
0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x16,0x15,
|
||||
0x15,0x15,0x15,0x15,0x13,0x13,0x12,0x12,0x12,0x12,0x11,0x11,0x10,0x10,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1c,0x1b,0x1b,0x1a,0x1a,0x1a,0x19,0x19,0x18,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x16,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x16,0x15,0x15,0x13,0x13,0x13,
|
||||
0x13,0x13,0x13,0x12,0x12,0x11,0x10,0x10,0x10,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1c,0x1c,0x1c,0x1b,0x1b,0x1a,0x19,0x19,0x19,0x17,0x17,0x18,0x17,0x17,
|
||||
0x17,0x17,0x17,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x13,0x12,0x12,
|
||||
0x12,0x11,0x11,0x10,0x10,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1c,0x1c,
|
||||
0x1b,0x1b,0x1a,0x1a,0x19,0x19,0x17,0x17,0x18,0x17,0x17,0x17,0x17,0x15,0x17,0x16,
|
||||
0x15,0x15,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x13,0x13,0x13,0x12,0x12,0x11,0x12,0x11,0x10,
|
||||
0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1c,0x1c,0x1b,0x1b,0x1a,0x1a,
|
||||
0x19,0x19,0x19,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x15,0x15,0x16,0x15,0x15,0x15,
|
||||
0x15,0x15,0x15,0x15,0x13,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
|
||||
0x13,0x13,0x13,0x15,0x12,0x12,0x12,0x11,0x12,0x11,0x11,0x10,0x10,0x10,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1c,0x1b,0x1a,0x1a,0x19,0x19,0x19,0x18,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x15,
|
||||
0x13,0x15,0x13,0x13,0x15,0x15,0x15,0x13,0x15,0x15,0x15,0x15,0x15,0x14,0x13,0x13,
|
||||
0x13,0x12,0x12,0x12,0x11,0x11,0x10,0x10,0x11,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1c,0x1c,0x1b,0x1a,0x1a,0x19,0x19,0x17,0x19,0x17,0x18,0x17,0x17,0x17,
|
||||
0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x13,0x15,0x14,0x13,0x13,
|
||||
0x15,0x13,0x13,0x13,0x13,0x13,0x14,0x15,0x13,0x15,0x13,0x13,0x13,0x12,0x12,0x11,
|
||||
0x11,0x11,0x11,0x10,0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1c,
|
||||
0x1b,0x1a,0x19,0x1a,0x19,0x18,0x17,0x17,0x17,0x17,0x17,0x16,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x15,0x15,0x13,0x15,0x13,0x14,0x13,0x13,0x13,0x13,0x15,0x13,0x13,0x15,
|
||||
0x15,0x13,0x14,0x13,0x13,0x13,0x13,0x12,0x13,0x13,0x12,0x11,0x12,0x11,0x11,0x10,
|
||||
0x10,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1c,0x1c,0x1b,0x1a,0x1a,0x19,
|
||||
0x19,0x17,0x17,0x17,0x18,0x17,0x17,0x15,0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x15,
|
||||
0x13,0x15,0x15,0x13,0x13,0x13,0x12,0x13,0x13,0x14,0x13,0x13,0x13,0x13,0x13,0x13,
|
||||
0x13,0x14,0x13,0x13,0x12,0x12,0x11,0x11,0x12,0x12,0x10,0x10,0x10,0x10,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1d,0x1b,0x1b,0x1a,0x19,0x19,0x18,0x17,0x17,0x17,
|
||||
0x17,0x15,0x16,0x17,0x15,0x15,0x15,0x15,0x15,0x13,0x15,0x15,0x14,0x13,0x13,0x13,
|
||||
0x13,0x13,0x12,0x13,0x13,0x14,0x13,0x13,0x13,0x12,0x13,0x13,0x13,0x13,0x14,0x13,
|
||||
0x13,0x12,0x12,0x12,0x11,0x11,0x11,0x10,0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1b,0x1c,0x1b,0x1a,0x19,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x16,0x15,
|
||||
0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x15,0x14,0x13,0x13,0x13,0x13,0x13,0x12,
|
||||
0x12,0x13,0x13,0x14,0x13,0x12,0x12,0x13,0x13,0x12,0x13,0x13,0x12,0x13,0x12,0x11,
|
||||
0x11,0x11,0x11,0x10,0x10,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1c,0x1b,
|
||||
0x1a,0x19,0x19,0x19,0x17,0x17,0x17,0x17,0x15,0x15,0x16,0x15,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x13,0x13,0x13,0x13,0x13,0x13,0x12,0x14,0x13,0x13,0x13,0x13,0x12,0x12,
|
||||
0x13,0x12,0x12,0x13,0x13,0x12,0x12,0x14,0x12,0x12,0x11,0x12,0x11,0x11,0x10,0x10,
|
||||
0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1b,0x1c,0x1a,0x19,0x19,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x15,
|
||||
0x12,0x12,0x13,0x12,0x13,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,
|
||||
0x13,0x12,0x12,0x12,0x13,0x12,0x12,0x12,0x11,0x10,0x11,0x10,0x10,0x0f,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1c,0x1a,0x19,0x19,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x16,0x15,0x15,0x15,0x15,0x15,0x13,0x15,0x15,0x15,0x14,0x13,0x13,0x12,0x13,0x12,
|
||||
0x12,0x13,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,
|
||||
0x12,0x12,0x12,0x12,0x11,0x11,0x10,0x10,0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1b,0x1b,0x1a,0x19,0x17,0x17,0x17,0x16,0x17,0x15,0x15,0x15,0x15,0x16,
|
||||
0x15,0x13,0x15,0x15,0x13,0x13,0x13,0x13,0x12,0x13,0x12,0x13,0x12,0x12,0x12,0x12,
|
||||
0x12,0x12,0x12,0x12,0x11,0x11,0x12,0x12,0x12,0x12,0x11,0x11,0x12,0x12,0x11,0x12,
|
||||
0x11,0x11,0x11,0x10,0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1c,0x1a,
|
||||
0x19,0x19,0x17,0x17,0x17,0x17,0x16,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x13,0x14,
|
||||
0x13,0x13,0x12,0x13,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,
|
||||
0x12,0x11,0x11,0x12,0x11,0x12,0x11,0x11,0x12,0x12,0x12,0x11,0x12,0x11,0x11,0x10,
|
||||
0x10,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1b,0x1a,0x19,0x19,0x17,0x17,
|
||||
0x15,0x17,0x15,0x16,0x15,0x15,0x15,0x15,0x15,0x13,0x15,0x13,0x13,0x13,0x12,0x14,
|
||||
0x12,0x12,0x12,0x12,0x12,0x12,0x11,0x12,0x11,0x12,0x11,0x11,0x12,0x11,0x12,0x12,
|
||||
0x11,0x12,0x12,0x12,0x11,0x11,0x11,0x11,0x11,0x10,0x11,0x10,0x10,0x0f,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1b,0x1a,0x19,0x17,0x17,0x17,0x15,0x15,0x16,0x15,
|
||||
0x15,0x15,0x13,0x15,0x13,0x13,0x13,0x12,0x12,0x12,0x14,0x12,0x12,0x12,0x12,0x12,
|
||||
0x11,0x12,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x12,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x10,0x10,0x0f,0x0f,0x10,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x1a,0x1a,0x19,0x19,0x17,0x15,0x17,0x15,0x15,0x15,0x15,0x15,0x15,0x13,
|
||||
0x13,0x13,0x14,0x13,0x12,0x12,0x12,0x11,0x12,0x12,0x12,0x12,0x11,0x11,0x11,0x12,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x11,0x11,0x11,0x11,0x11,0x10,
|
||||
0x11,0x11,0x10,0x10,0x0f,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1a,0x19,
|
||||
0x17,0x17,0x17,0x15,0x15,0x16,0x15,0x15,0x15,0x13,0x13,0x13,0x13,0x13,0x12,0x12,
|
||||
0x12,0x12,0x12,0x12,0x11,0x12,0x11,0x11,0x11,0x12,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x10,0x11,0x11,0x10,0x11,0x11,0x11,0x11,0x10,0x11,0x11,0x10,0x10,
|
||||
0x0f,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x19,0x1a,0x17,0x17,0x17,0x16,
|
||||
0x15,0x15,0x15,0x13,0x15,0x15,0x13,0x13,0x13,0x12,0x13,0x12,0x12,0x11,0x12,0x12,
|
||||
0x11,0x12,0x11,0x11,0x11,0x11,0x10,0x11,0x10,0x10,0x11,0x11,0x11,0x10,0x11,0x11,
|
||||
0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,0x10,0x10,0x0b,0x17,
|
||||
0x17,0x3f,0x3f,0x3f,0x0f,0x19,0x1a,0x19,0x17,0x15,0x15,0x15,0x15,0x15,0x15,0x13,
|
||||
0x12,0x14,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x10,
|
||||
0x11,0x11,0x11,0x10,0x11,0x11,0x10,0x10,0x0f,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,
|
||||
0x0f,0x19,0x19,0x17,0x17,0x16,0x15,0x15,0x15,0x13,0x13,0x12,0x13,0x12,0x12,0x11,
|
||||
0x12,0x12,0x12,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x11,0x10,
|
||||
0x10,0x10,0x11,0x11,0x10,0x10,0x10,0x10,0x11,0x10,0x11,0x10,0x11,0x10,0x10,0x10,
|
||||
0x10,0x10,0x10,0x10,0x10,0x0f,0x0b,0x17,0x17,0x3f,0x3f,0x3f,0x1e,0x0f,0x19,0x17,
|
||||
0x17,0x15,0x15,0x15,0x15,0x13,0x13,0x14,0x12,0x12,0x12,0x12,0x12,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,0x11,0x10,0x11,0x10,0x10,0x10,
|
||||
0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x0f,
|
||||
0x10,0x0b,0x17,0x17,0x1b,0x3f,0x3f,0x3f,0x1b,0x0f,0x17,0x17,0x16,0x15,0x15,0x13,
|
||||
0x13,0x12,0x13,0x12,0x12,0x11,0x11,0x12,0x11,0x11,0x11,0x11,0x10,0x10,0x10,0x11,
|
||||
0x10,0x11,0x10,0x11,0x10,0x10,0x10,0x10,0x0f,0x10,0x10,0x10,0x10,0x10,0x10,0x10,
|
||||
0x10,0x10,0x10,0x10,0x0f,0x10,0x10,0x0f,0x10,0x10,0x10,0x10,0x10,0x0b,0x17,0x17,
|
||||
0x1b,0x3f,0x3f,0x3f,0x1b,0x1b,0x0f,0x17,0x15,0x13,0x13,0x13,0x12,0x12,0x12,0x12,
|
||||
0x11,0x11,0x12,0x11,0x11,0x11,0x10,0x11,0x10,0x11,0x11,0x10,0x10,0x10,0x10,0x10,
|
||||
0x10,0x10,0x10,0x10,0x10,0x0f,0x10,0x0f,0x10,0x10,0x10,0x10,0x10,0x0f,0x0f,0x0f,
|
||||
0x10,0x0f,0x10,0x10,0x0f,0x0f,0x0f,0x10,0x0b,0x17,0x17,0x1b,0x1b,0x3f,0x3f,0x3f,
|
||||
0x1b,0x1b,0x0f,0x17,0x15,0x15,0x12,0x12,0x12,0x11,0x11,0x11,0x11,0x10,0x10,0x11,
|
||||
0x10,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,
|
||||
0x10,0x0f,0x0f,0x0f,0x0f,0x0f,0x10,0x0f,0x0f,0x0f,0x0f,0x10,0x0f,0x0f,0x0f,0x0f,
|
||||
0x0f,0x10,0x0f,0x0f,0x0b,0x17,0x17,0x1b,0x1b,0x3f,0x3f,0x3f,0x1b,0x1b,0x1b,0x0b,
|
||||
0x0b,0x12,0x11,0x12,0x11,0x11,0x10,0x11,0x10,0x10,0x10,0x10,0x10,0x0f,0x10,0x10,
|
||||
0x0f,0x0f,0x10,0x10,0x0f,0x0f,0x10,0x10,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x10,
|
||||
0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x10,0x0f,0x0f,0x0f,0x0f,0x0b,0x0b,
|
||||
0x17,0x17,0x1b,0x1b,0x1b,0x3f,0x3f,0x3f,0x1b,0x1b,0x1b,0x1b,0x1b,0x0b,0x10,0x10,
|
||||
0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x0f,0x0f,0x10,0x0f,0x0f,0x0f,
|
||||
0x0f,0x0f,0x10,0x0f,0x0f,0x0f,0x10,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,
|
||||
0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0b,0x0b,0x17,0x17,0x17,0x1b,0x1b,0x1b,
|
||||
0x1b,0x3f,0x3f,0x3f,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,
|
||||
0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,
|
||||
0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,
|
||||
0x0b,0x0b,0x0b,0x0b,0x17,0x17,0x17,0x17,0x1b,0x1b,0x1b,0x1b,0x1b,0x3f,0x3f,0x3f,
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x3f,0x3f,0x3f,0x1b,0x1b,0x1b,0x1b,
|
||||
0x1b,0x1b,0x1b,0x1b,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
|
||||
0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x1b,0x1b,0x1b,0x1b,
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x3f,0x3f,0x3f
|
||||
};
|
||||
|
||||
|
||||
const int32 kMouseDownWidth = 55;
|
||||
const int32 kMouseDownHeight = 29;
|
||||
const color_space kMouseDownColorSpace = B_CMAP8;
|
||||
|
||||
const unsigned char kMouseDownBits [] = {
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,
|
||||
0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,
|
||||
0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,0x09,0x08,
|
||||
0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x1b,0x3f,0x1b,0x1b,0x1b,0x1b,0x1b,0x08,0x09,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x06,0x06,0x1b,0x1b,0x1b,0x1b,0x1b,0x3f,
|
||||
0x1b,0x1b,0x1b,0x08,0x09,0x11,0x11,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x14,0x13,
|
||||
0x13,0x13,0x13,0x13,0x13,0x13,0x14,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x14,
|
||||
0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x14,0x13,0x13,0x13,0x13,0x11,0x13,
|
||||
0x11,0x11,0x06,0x06,0x18,0x1b,0x1b,0x3f,0x1b,0x1b,0x08,0x11,0x11,0x13,0x13,0x15,
|
||||
0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
|
||||
0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x11,0x11,0x11,0x07,0x17,0x17,0x3f,
|
||||
0x1b,0x1b,0x08,0x11,0x13,0x13,0x15,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,
|
||||
0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,
|
||||
0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x0f,0x07,0x17,0x3f,0x1b,0x08,0x11,0x13,0x13,0x15,0x13,0x13,
|
||||
0x13,0x13,0x14,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,
|
||||
0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x13,0x13,0x13,0x13,0x11,0x13,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x07,0x17,0x3f,
|
||||
0x1b,0x08,0x11,0x13,0x15,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,
|
||||
0x13,0x14,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x13,
|
||||
0x11,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x0f,0x0f,0x0d,0x0d,0x06,0x3f,0x08,0x11,0x13,0x13,0x15,0x13,0x13,0x13,
|
||||
0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,
|
||||
0x13,0x11,0x13,0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0d,0x0d,0x0d,0x06,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x15,0x13,0x13,0x11,0x13,0x13,0x13,0x11,0x13,0x13,0x13,0x13,
|
||||
0x13,0x11,0x13,0x13,0x13,0x13,0x13,0x11,0x13,0x11,0x13,0x13,0x11,0x11,0x13,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x0f,0x0f,0x0f,0x0d,0x0c,0x06,0x3f,0x08,0x11,0x13,0x13,0x15,0x13,0x13,0x13,
|
||||
0x13,0x13,0x11,0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x13,0x13,0x13,0x11,0x11,0x13,
|
||||
0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x0d,0x0d,0x0d,0x0c,0x07,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x15,0x13,0x11,0x11,0x11,0x11,0x13,0x13,0x13,0x13,0x11,0x11,
|
||||
0x11,0x11,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,
|
||||
0x0f,0x0f,0x0f,0x0d,0x0c,0x0b,0x06,0x3f,0x08,0x11,0x13,0x13,0x15,0x13,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x13,0x11,0x13,0x11,0x11,0x11,0x11,0x13,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0d,0x0c,0x06,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x15,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x0f,
|
||||
0x0f,0x0d,0x0d,0x0d,0x0c,0x0b,0x06,0x3f,0x08,0x11,0x13,0x13,0x15,0x13,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0c,0x0d,0x0b,0x06,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x15,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,
|
||||
0x0f,0x0d,0x0d,0x0c,0x0b,0x0b,0x06,0x3f,0x08,0x11,0x13,0x13,0x15,0x13,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0d,0x0c,0x0c,0x0b,0x06,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x15,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,
|
||||
0x0d,0x0d,0x0d,0x0c,0x0b,0x0a,0x07,0x3f,0x08,0x11,0x13,0x13,0x15,0x13,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0d,0x0b,0x0c,0x0a,0x07,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,
|
||||
0x0d,0x0d,0x0d,0x0c,0x0b,0x0b,0x06,0x3f,0x08,0x11,0x13,0x13,0x13,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,
|
||||
0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0d,0x0c,0x0c,0x0c,0x0b,0x0a,0x07,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x0f,0x11,0x11,0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0d,
|
||||
0x0d,0x0c,0x0c,0x0c,0x0a,0x0b,0x06,0x3f,0x08,0x11,0x13,0x13,0x13,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,
|
||||
0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0d,0x0d,0x0c,0x0c,0x0b,0x0b,0x0a,0x07,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0d,0x0d,
|
||||
0x0d,0x0c,0x0c,0x0c,0x0a,0x0b,0x06,0x3f,0x08,0x11,0x13,0x13,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,
|
||||
0x0f,0x0f,0x0f,0x0f,0x0f,0x0d,0x0d,0x0d,0x0d,0x0c,0x0b,0x0b,0x0a,0x0b,0x06,0x3f,
|
||||
0x08,0x11,0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
|
||||
0x11,0x11,0x11,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0e,0x0d,0x0d,0x0d,0x0d,
|
||||
0x0d,0x0c,0x0c,0x0b,0x0b,0x0b,0x06,0x3f,0x08,0x11,0x13,0x13,0x11,0x0f,0x0f,0x0f,
|
||||
0x0f,0x0e,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0e,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,
|
||||
0x0f,0x0e,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0e,0x0f,0x0d,0x0d,0x0d,0x0d,0x0d,
|
||||
0x0d,0x0d,0x0d,0x0d,0x0d,0x0d,0x0d,0x0d,0x0d,0x0d,0x0b,0x0b,0x0b,0x0a,0x07,0x3f,
|
||||
0x08,0x11,0x13,0x0f,0x0f,0x06,0x07,0x06,0x06,0x07,0x06,0x06,0x07,0x06,0x07,0x06,
|
||||
0x06,0x07,0x06,0x06,0x07,0x06,0x07,0x06,0x06,0x07,0x06,0x06,0x07,0x06,0x07,0x06,
|
||||
0x06,0x07,0x06,0x06,0x07,0x06,0x07,0x06,0x06,0x07,0x06,0x06,0x07,0x06,0x07,0x06,
|
||||
0x06,0x07,0x0a,0x0b,0x0b,0x0a,0x07,0x3f,0x08,0x11,0x0f,0x06,0x07,0x1e,0x1e,0x1e,
|
||||
0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,
|
||||
0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,
|
||||
0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x1e,0x06,0x06,0x0b,0x0b,0x06,0x3f,
|
||||
0x08,0x06,0x07,0x1e,0x1e,0x1e,0x1c,0x1b,0x1b,0x1a,0x1a,0x1a,0x1a,0x19,0x19,0x19,
|
||||
0x17,0x19,0x19,0x19,0x19,0x19,0x19,0x17,0x19,0x19,0x19,0x19,0x19,0x19,0x18,0x17,
|
||||
0x17,0x18,0x17,0x18,0x17,0x17,0x17,0x15,0x17,0x17,0x17,0x15,0x15,0x15,0x15,0x13,
|
||||
0x14,0x17,0x17,0x18,0x06,0x06,0x07,0x3f
|
||||
};
|
||||
|
||||
|
@ -1,8 +1,17 @@
|
||||
/*
|
||||
|
||||
MouseMessages.h
|
||||
|
||||
*/
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: MouseMessages.h
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
|
||||
#ifndef MOUSE_MESSAGES_H
|
||||
#define MOUSE_MESSAGES_H
|
||||
@ -11,11 +20,14 @@ const uint32 BUTTON_DEFAULTS = 'BTde';
|
||||
const uint32 BUTTON_REVERT = 'BTre';
|
||||
|
||||
const uint32 POPUP_MOUSE_TYPE = 'PUmt';
|
||||
const uint32 POPUP_MOUSE_FOCUS = 'PUmf';
|
||||
const uint32 POPUP_MOUSE_MAP = 'PUmm';
|
||||
|
||||
const uint32 DOUBLE_CLICK_TEST_AREA = 'TCte';
|
||||
|
||||
const uint32 SLIDER_DOUBLE_CLICK_SPEED = 'SLdc';
|
||||
const uint32 SLIDER_MOUSE_SPEED = 'SLms';
|
||||
const uint32 SLIDER_MOUSE_ACC = 'SLma';
|
||||
|
||||
const uint32 ERROR_DETECTED = 'ERor';
|
||||
|
||||
|
@ -1,9 +1,18 @@
|
||||
/*
|
||||
* MouseSettings.cpp
|
||||
* Mouse mccall@digitalparadise.co.uk
|
||||
*
|
||||
*/
|
||||
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: MouseSettings.h
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
|
||||
#include <Application.h>
|
||||
#include <FindDirectory.h>
|
||||
#include <File.h>
|
||||
@ -14,10 +23,11 @@
|
||||
#include "MouseSettings.h"
|
||||
#include "MouseMessages.h"
|
||||
|
||||
const char MouseSettings::kMouseSettingsFile[] = "Mouse_settings";
|
||||
const char kMouseSettingsFile[] = "Mouse_settings";
|
||||
|
||||
MouseSettings::MouseSettings()
|
||||
{
|
||||
fInitCheck = B_OK;
|
||||
BPath path;
|
||||
|
||||
if (find_directory(B_USER_SETTINGS_DIRECTORY,&path) == B_OK) {
|
||||
@ -25,39 +35,39 @@ MouseSettings::MouseSettings()
|
||||
BFile file(path.Path(), B_READ_ONLY);
|
||||
if (file.InitCheck() == B_OK) {
|
||||
// Now read in the data
|
||||
if (file.Read(&fSettings, sizeof(mouse_settings)) != sizeof(mouse_settings)) {
|
||||
// we have to do this because mouse_map counts 16 buttons in OBOS
|
||||
if ((file.Read(&fSettings.type, sizeof(fSettings.type)) != sizeof(fSettings.type))
|
||||
||(file.Read(&fSettings.map, (3*sizeof(int32))) != (3*sizeof(int32)))
|
||||
|| (file.Read(&fSettings.accel, sizeof(fSettings.accel)) != sizeof(fSettings.accel))
|
||||
|| (file.Read(&fSettings.click_speed, sizeof(fSettings.click_speed)) != sizeof(fSettings.click_speed))) {
|
||||
if (get_mouse_type((int32*)&fSettings.type) != B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
fInitCheck = B_ERROR;
|
||||
if (get_mouse_map(&fSettings.map) != B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
if (get_mouse_speed((int32 *)&fSettings.accel.speed) != B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
fInitCheck = B_ERROR;
|
||||
if (get_mouse_speed(&fSettings.accel.speed) != B_OK)
|
||||
fInitCheck = B_ERROR;
|
||||
if (get_click_speed(&fSettings.click_speed) != B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
fInitCheck = B_ERROR;
|
||||
}
|
||||
|
||||
if (file.Read(&fCorner, sizeof(BPoint)) != sizeof(BPoint)) {
|
||||
fCorner.x=50;
|
||||
fCorner.y=50;
|
||||
}
|
||||
}
|
||||
else {
|
||||
}
|
||||
} else {
|
||||
if (get_mouse_type((int32*)&fSettings.type) != B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
fInitCheck = B_ERROR;
|
||||
if (get_mouse_map(&fSettings.map) != B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
|
||||
fInitCheck = B_ERROR;
|
||||
if (get_mouse_speed(&fSettings.accel.speed) != B_OK)
|
||||
fInitCheck = B_ERROR;
|
||||
if (get_click_speed(&fSettings.click_speed) != B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
fInitCheck = B_ERROR;
|
||||
fCorner.x=50;
|
||||
fCorner.y=50;
|
||||
}
|
||||
}
|
||||
else
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
|
||||
printf("Size is : %ld\n",sizeof(mouse_settings)+sizeof(BPoint));
|
||||
|
||||
} else
|
||||
fInitCheck = B_ERROR;
|
||||
}
|
||||
|
||||
MouseSettings::~MouseSettings()
|
||||
@ -69,31 +79,46 @@ MouseSettings::~MouseSettings()
|
||||
|
||||
path.Append(kMouseSettingsFile);
|
||||
|
||||
BFile file(path.Path(), B_WRITE_ONLY | B_CREATE_FILE);
|
||||
BFile file(path.Path(), B_READ_WRITE | B_CREATE_FILE | B_ERASE_FILE);
|
||||
if (file.InitCheck() == B_OK) {
|
||||
file.Write(&fSettings, sizeof(mouse_settings));
|
||||
// we have to do this because mouse_map counts 16 buttons in OBOS
|
||||
file.Write(&fSettings.type, sizeof(fSettings.type));
|
||||
file.Write(&fSettings.map, 3*sizeof(int32));
|
||||
file.Write(&fSettings.accel, sizeof(fSettings.accel));
|
||||
file.Write(&fSettings.click_speed, sizeof(fSettings.click_speed));
|
||||
file.Write(&fCorner, sizeof(BPoint));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
status_t
|
||||
MouseSettings::InitCheck()
|
||||
{
|
||||
return fInitCheck;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
MouseSettings::SetWindowCorner(BPoint corner)
|
||||
{
|
||||
fCorner=corner;
|
||||
fCorner = corner;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
MouseSettings::SetMouseType(mouse_type type)
|
||||
MouseSettings::SetMouseType(int32 type)
|
||||
{
|
||||
fSettings.type=type;
|
||||
fSettings.type = type;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
MouseSettings::SetClickSpeed(bigtime_t click_speed)
|
||||
{
|
||||
fSettings.click_speed=-(click_speed-1000000);
|
||||
fSettings.click_speed = -(click_speed-1000000);
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
MouseSettings::SetMouseSpeed(int32 accel)
|
||||
{
|
||||
|
@ -1,16 +1,24 @@
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: MouseSettings.h
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
|
||||
#ifndef MOUSE_SETTINGS_H_
|
||||
#define MOUSE_SETTINGS_H_
|
||||
|
||||
#include <SupportDefs.h>
|
||||
#include <InterfaceDefs.h>
|
||||
|
||||
typedef enum {
|
||||
MOUSE_1_BUTTON = 1,
|
||||
MOUSE_2_BUTTON,
|
||||
MOUSE_3_BUTTON
|
||||
} mouse_type;
|
||||
|
||||
|
||||
typedef struct {
|
||||
bool enabled; // Acceleration on / off
|
||||
int32 accel_factor; // accel factor: 256 = step by 1, 128 = step by 1/2
|
||||
@ -18,7 +26,7 @@ typedef struct {
|
||||
} mouse_accel;
|
||||
|
||||
typedef struct {
|
||||
mouse_type type;
|
||||
int32 type;
|
||||
mouse_map map;
|
||||
mouse_accel accel;
|
||||
bigtime_t click_speed;
|
||||
@ -28,18 +36,19 @@ class MouseSettings{
|
||||
public :
|
||||
MouseSettings();
|
||||
~MouseSettings();
|
||||
status_t InitCheck();
|
||||
|
||||
BPoint WindowCorner() const { return fCorner; }
|
||||
void SetWindowCorner(BPoint corner);
|
||||
mouse_type MouseType() const { return fSettings.type; }
|
||||
void SetMouseType(mouse_type type);
|
||||
int32 MouseType() const { return fSettings.type; }
|
||||
void SetMouseType(int32 type);
|
||||
bigtime_t ClickSpeed() const { return -(fSettings.click_speed-1000000); } // -1000000 to correct the Sliders 0-100000 scale
|
||||
void SetClickSpeed(bigtime_t click_speed);
|
||||
int32 MouseSpeed() const { return fSettings.accel.speed; }
|
||||
void SetMouseSpeed(int32 speed);
|
||||
|
||||
private:
|
||||
static const char kMouseSettingsFile[];
|
||||
status_t fInitCheck;
|
||||
BPoint fCorner;
|
||||
mouse_settings fSettings;
|
||||
};
|
||||
|
@ -1,8 +1,18 @@
|
||||
/*
|
||||
|
||||
MouseView.cpp
|
||||
|
||||
*/
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: MouseView.cpp
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
|
||||
#include <InterfaceDefs.h>
|
||||
#include <Button.h>
|
||||
#include <Box.h>
|
||||
@ -13,21 +23,68 @@
|
||||
#include <PopUpMenu.h>
|
||||
#include <MenuField.h>
|
||||
#include <MenuItem.h>
|
||||
#include <Debug.h>
|
||||
#include <Window.h>
|
||||
|
||||
#include "MouseView.h"
|
||||
#include "MouseMessages.h"
|
||||
#include "MouseBitmap.h"
|
||||
|
||||
BoxView::BoxView(BRect rect, MouseView *mouseView)
|
||||
: BBox(rect, "mouse_box",
|
||||
B_FOLLOW_LEFT, B_WILL_DRAW,B_FANCY_BORDER),
|
||||
fMouseView(mouseView)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
BoxView::MouseDown(BPoint where)
|
||||
{
|
||||
|
||||
int32 index = fMouseView->mouseTypeMenu->IndexOf(fMouseView->mouseTypeMenu->FindMarked());
|
||||
|
||||
fMouseView->fCurrentButton = -1;
|
||||
if ((index == 0) && BRect(50,41,105,73).Contains(where))
|
||||
fMouseView->fCurrentButton = 0;
|
||||
else if (index == 1) {
|
||||
if(BRect(50,41,77,73).Contains(where))
|
||||
fMouseView->fCurrentButton = 0;
|
||||
else if (BRect(77,41,105,73).Contains(where))
|
||||
fMouseView->fCurrentButton = 1;
|
||||
} else {
|
||||
if(BRect(50,41,68,73).Contains(where))
|
||||
fMouseView->fCurrentButton = 0;
|
||||
else if (BRect(86,41,105,73).Contains(where))
|
||||
fMouseView->fCurrentButton = 1;
|
||||
else if (BRect(68,41,86,73).Contains(where))
|
||||
fMouseView->fCurrentButton = 2;
|
||||
}
|
||||
|
||||
if (fMouseView->fCurrentButton >= 0) {
|
||||
int32 number = 0;
|
||||
switch (fMouseView->fCurrentMouseMap.button[fMouseView->fCurrentButton]) {
|
||||
case B_PRIMARY_MOUSE_BUTTON: number = 0; break;
|
||||
case B_SECONDARY_MOUSE_BUTTON: number = 1; break;
|
||||
case B_TERTIARY_MOUSE_BUTTON: number = 2; break;
|
||||
}
|
||||
fMouseView->mouseMapMenu->ItemAt(number)->SetMarked(true);
|
||||
ConvertToScreen(&where);
|
||||
fMouseView->mouseMapMenu->Go(where, true);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
MouseView::MouseView(BRect rect)
|
||||
: BBox(rect, "mouse_view",
|
||||
B_FOLLOW_ALL, B_WILL_DRAW | B_FRAME_EVENTS | B_NAVIGABLE_JUMP,
|
||||
B_PLAIN_BORDER)
|
||||
B_FOLLOW_ALL, B_WILL_DRAW | B_FRAME_EVENTS | B_NAVIGABLE_JUMP | B_PULSE_NEEDED,
|
||||
B_PLAIN_BORDER),
|
||||
fCurrentButton(-1),
|
||||
fButtons(0),
|
||||
fOldButtons(0)
|
||||
{
|
||||
BRect frame;
|
||||
BButton *button;
|
||||
BTextControl *textcontrol;
|
||||
BSlider *slider;
|
||||
BPopUpMenu *popupmenu;
|
||||
BMenuField *menufield;
|
||||
|
||||
SetViewColor(ui_color(B_PANEL_BACKGROUND_COLOR));
|
||||
@ -36,16 +93,25 @@ MouseView::MouseView(BRect rect)
|
||||
fSpeedBitmap = BTranslationUtils::GetBitmap("speed_bmap");
|
||||
fAccelerationBitmap = BTranslationUtils::GetBitmap("acceleration_bmap");
|
||||
|
||||
// i don't really understand this bitmap SetBits : i have to substract 4 lines and add 15 pixels
|
||||
BRect mouseRect(0,0,kMouseWidth-1,kMouseHeight-5);
|
||||
fMouseBitmap = new BBitmap(mouseRect, B_CMAP8);
|
||||
fMouseBitmap->SetBits(kMouseBits, kMouseWidth*kMouseHeight + 15, 0, kMouseColorSpace);
|
||||
|
||||
BRect mouseDownRect(0,0,kMouseDownWidth-1,kMouseDownHeight-1);
|
||||
fMouseDownBitmap = new BBitmap(mouseDownRect, B_CMAP8);
|
||||
fMouseDownBitmap->SetBits(kMouseDownBits, kMouseDownWidth*kMouseDownHeight + 30, 0, kMouseDownColorSpace);
|
||||
|
||||
// Add the "Default" button..
|
||||
frame.Set(10,259,85,279);
|
||||
button = new BButton(frame,"mouse_defaults","Defaults", new BMessage(BUTTON_DEFAULTS));
|
||||
AddChild(button);
|
||||
defaultButton = new BButton(frame,"mouse_defaults","Defaults", new BMessage(BUTTON_DEFAULTS));
|
||||
AddChild(defaultButton);
|
||||
|
||||
// Add the "Revert" button...
|
||||
frame.Set(92,259,167,279);
|
||||
button = new BButton(frame,"mouse_revert","Revert", new BMessage(BUTTON_REVERT));
|
||||
button->SetEnabled(false);
|
||||
AddChild(button);
|
||||
revertButton = new BButton(frame,"mouse_revert","Revert", new BMessage(BUTTON_REVERT));
|
||||
revertButton->SetEnabled(false);
|
||||
AddChild(revertButton);
|
||||
|
||||
// Create the main box for the controls...
|
||||
frame=Bounds();
|
||||
@ -53,58 +119,61 @@ MouseView::MouseView(BRect rect)
|
||||
frame.top=frame.top+11;
|
||||
frame.right=frame.right-11;
|
||||
frame.bottom=frame.bottom-44;
|
||||
fBox = new BBox(frame,"mouse_box",B_FOLLOW_LEFT,B_WILL_DRAW,B_FANCY_BORDER);
|
||||
fBox = new BoxView(frame, this);
|
||||
|
||||
// Add the "Mouse Type" pop up menu
|
||||
popupmenu = new BPopUpMenu("Mouse Type Menu");
|
||||
popupmenu->AddItem(new BMenuItem("1-Button",new BMessage(POPUP_MOUSE_TYPE)));
|
||||
popupmenu->AddItem(new BMenuItem("2-Button",new BMessage(POPUP_MOUSE_TYPE)));
|
||||
popupmenu->AddItem(new BMenuItem("3-Button",new BMessage(POPUP_MOUSE_TYPE)));
|
||||
mouseTypeMenu = new BPopUpMenu("Mouse Type Menu");
|
||||
mouseTypeMenu->AddItem(new BMenuItem("1-Button",new BMessage(POPUP_MOUSE_TYPE)));
|
||||
mouseTypeMenu->AddItem(new BMenuItem("2-Button",new BMessage(POPUP_MOUSE_TYPE)));
|
||||
mouseTypeMenu->AddItem(new BMenuItem("3-Button",new BMessage(POPUP_MOUSE_TYPE)));
|
||||
|
||||
frame.Set(18,10,208,20);
|
||||
menufield = new BMenuField(frame, "mouse_type", "Mouse Type", popupmenu);
|
||||
menufield->SetDivider(menufield->Divider() - 30);
|
||||
frame.Set(17,8,208,20);
|
||||
menufield = new BMenuField(frame, "mouse_type", "Mouse type", mouseTypeMenu);
|
||||
menufield->SetDivider(menufield->Divider() - 34);
|
||||
fBox->AddChild(menufield);
|
||||
|
||||
// Add the "Mouse Type" pop up menu
|
||||
popupmenu = new BPopUpMenu("Focus Follows Mouse Menu");
|
||||
popupmenu->AddItem(new BMenuItem("Disabled",new BMessage(BUTTON_REVERT)));
|
||||
popupmenu->AddItem(new BMenuItem("Enabled",new BMessage(BUTTON_REVERT)));
|
||||
popupmenu->AddItem(new BMenuItem("Warping",new BMessage(BUTTON_REVERT)));
|
||||
popupmenu->AddItem(new BMenuItem("Instant-Warping",new BMessage(BUTTON_REVERT)));
|
||||
// Add the "Focus follows mouse" pop up menu
|
||||
focusMenu = new BPopUpMenu("Focus Follows Mouse Menu");
|
||||
focusMenu->AddItem(new BMenuItem("Disabled",new BMessage(POPUP_MOUSE_FOCUS)));
|
||||
focusMenu->AddItem(new BMenuItem("Enabled",new BMessage(POPUP_MOUSE_FOCUS)));
|
||||
focusMenu->AddItem(new BMenuItem("Warping",new BMessage(POPUP_MOUSE_FOCUS)));
|
||||
focusMenu->AddItem(new BMenuItem("Instant-Warping",new BMessage(POPUP_MOUSE_FOCUS)));
|
||||
|
||||
frame.Set(168,207,440,200);
|
||||
menufield = new BMenuField(frame, "Focus follows mouse", "Focus follows mouse:", popupmenu);
|
||||
menufield->SetDivider(menufield->Divider() - 30);
|
||||
frame.Set(165,208,440,200);
|
||||
menufield = new BMenuField(frame, "Focus follows mouse", "Focus follows mouse:", focusMenu);
|
||||
menufield->SetDivider(menufield->Divider() - 32);
|
||||
fBox->AddChild(menufield);
|
||||
|
||||
// Create the "Double-click speed slider...
|
||||
frame.Set(168,10,328,50);
|
||||
slider = new BSlider(frame,"double_click_speed","Double-click speed", new BMessage(SLIDER_DOUBLE_CLICK_SPEED),0,1000000,B_BLOCK_THUMB,B_FOLLOW_LEFT,B_WILL_DRAW);
|
||||
slider->SetHashMarks(B_HASH_MARKS_BOTTOM);
|
||||
slider->SetHashMarkCount(5);
|
||||
slider->SetLimitLabels("Slow","Fast");
|
||||
fBox->AddChild(slider);
|
||||
frame.Set(166,11,328,50);
|
||||
dcSpeedSlider = new BSlider(frame,"double_click_speed","Double-click speed",
|
||||
new BMessage(SLIDER_DOUBLE_CLICK_SPEED),0,1000,B_BLOCK_THUMB,B_FOLLOW_LEFT,B_WILL_DRAW);
|
||||
dcSpeedSlider->SetHashMarks(B_HASH_MARKS_BOTTOM);
|
||||
dcSpeedSlider->SetHashMarkCount(5);
|
||||
dcSpeedSlider->SetLimitLabels("Slow","Fast");
|
||||
fBox->AddChild(dcSpeedSlider);
|
||||
|
||||
// Create the "Mouse Speed" slider...
|
||||
frame.Set(168,75,328,125);
|
||||
slider = new BSlider(frame,"mouse_speed","Mouse Speed", new BMessage(SLIDER_MOUSE_SPEED),8192,524287,B_BLOCK_THUMB,B_FOLLOW_LEFT,B_WILL_DRAW);
|
||||
slider->SetHashMarks(B_HASH_MARKS_BOTTOM);
|
||||
slider->SetHashMarkCount(7);
|
||||
slider->SetLimitLabels("Slow","Fast");
|
||||
fBox->AddChild(slider);
|
||||
frame.Set(166,76,328,125);
|
||||
mouseSpeedSlider = new BSlider(frame,"mouse_speed","Mouse Speed",
|
||||
new BMessage(SLIDER_MOUSE_SPEED),0,1000,B_BLOCK_THUMB,B_FOLLOW_LEFT,B_WILL_DRAW);
|
||||
mouseSpeedSlider->SetHashMarks(B_HASH_MARKS_BOTTOM);
|
||||
mouseSpeedSlider->SetHashMarkCount(7);
|
||||
mouseSpeedSlider->SetLimitLabels("Slow","Fast");
|
||||
fBox->AddChild(mouseSpeedSlider);
|
||||
|
||||
// Create the "Mouse Acceleration" slider...
|
||||
frame.Set(168,140,328,190);
|
||||
slider = new BSlider(frame,"mouse_acceleration","Mouse Acceleration", new BMessage(SLIDER_MOUSE_SPEED),250000,1000000,B_BLOCK_THUMB,B_FOLLOW_LEFT,B_WILL_DRAW);
|
||||
slider->SetHashMarks(B_HASH_MARKS_BOTTOM);
|
||||
slider->SetHashMarkCount(5);
|
||||
slider->SetLimitLabels("Slow","Fast");
|
||||
fBox->AddChild(slider);
|
||||
frame.Set(166,141,328,190);
|
||||
mouseAccSlider = new BSlider(frame,"mouse_acceleration","Mouse Acceleration",
|
||||
new BMessage(SLIDER_MOUSE_ACC),0,1000,B_BLOCK_THUMB,B_FOLLOW_LEFT,B_WILL_DRAW);
|
||||
mouseAccSlider->SetHashMarks(B_HASH_MARKS_BOTTOM);
|
||||
mouseAccSlider->SetHashMarkCount(5);
|
||||
mouseAccSlider->SetLimitLabels("Slow","Fast");
|
||||
fBox->AddChild(mouseAccSlider);
|
||||
|
||||
// Create the "Double-click test area" text box...
|
||||
frame=fBox->Bounds();
|
||||
frame.left=frame.left+10;
|
||||
frame.left=frame.left+9;
|
||||
frame.right=frame.right-230;
|
||||
frame.top=frame.bottom-30;
|
||||
textcontrol = new BTextControl(frame,"double_click_test_area",NULL,"Double-click test area", new BMessage(DOUBLE_CLICK_TEST_AREA),B_FOLLOW_LEFT,B_WILL_DRAW);
|
||||
@ -113,25 +182,198 @@ MouseView::MouseView(BRect rect)
|
||||
|
||||
AddChild(fBox);
|
||||
|
||||
mouseMapMenu = new BPopUpMenu("Mouse Map Menu", true, true);
|
||||
mouseMapMenu->AddItem(new BMenuItem("1",new BMessage(POPUP_MOUSE_MAP)));
|
||||
mouseMapMenu->AddItem(new BMenuItem("2",new BMessage(POPUP_MOUSE_MAP)));
|
||||
mouseMapMenu->AddItem(new BMenuItem("3",new BMessage(POPUP_MOUSE_MAP)));
|
||||
|
||||
}
|
||||
|
||||
void MouseView::Draw(BRect updateFrame)
|
||||
|
||||
void
|
||||
MouseView::AttachedToWindow()
|
||||
{
|
||||
get_click_speed(&fClickSpeed);
|
||||
get_mouse_speed(&fMouseSpeed);
|
||||
get_mouse_acceleration(&fMouseAcc);
|
||||
get_mouse_type(&fMouseType);
|
||||
fMouseMode = mouse_mode();
|
||||
get_mouse_map(&fMouseMap);
|
||||
get_mouse_map(&fCurrentMouseMap);
|
||||
Init();
|
||||
|
||||
mouseMapMenu->SetTargetForItems( this->Window() );
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
MouseView::Pulse()
|
||||
{
|
||||
BPoint point;
|
||||
GetMouse(&point, &fButtons, true);
|
||||
|
||||
if (fOldButtons != fButtons) {
|
||||
Invalidate();
|
||||
fOldButtons = fButtons;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
MouseView::Draw(BRect updateFrame)
|
||||
{
|
||||
inherited::Draw(updateFrame);
|
||||
fBox->SetHighColor(120,120,120);
|
||||
fBox->SetLowColor(255,255,255);
|
||||
// Line above the test area
|
||||
fBox->StrokeLine(BPoint(10,199),BPoint(150,199),B_SOLID_HIGH);
|
||||
fBox->StrokeLine(BPoint(11,200),BPoint(150,200),B_SOLID_LOW);
|
||||
fBox->StrokeLine(BPoint(8,198),BPoint(149,198),B_SOLID_HIGH);
|
||||
fBox->StrokeLine(BPoint(8,199),BPoint(149,199),B_SOLID_LOW);
|
||||
// Line above focus follows mouse
|
||||
fBox->StrokeLine(BPoint(170,199),BPoint(362,199),B_SOLID_HIGH);
|
||||
fBox->StrokeLine(BPoint(171,200),BPoint(362,200),B_SOLID_LOW);
|
||||
fBox->StrokeLine(BPoint(164,198),BPoint(367,198),B_SOLID_HIGH);
|
||||
fBox->StrokeLine(BPoint(164,199),BPoint(367,199),B_SOLID_LOW);
|
||||
// Line in the middle
|
||||
fBox->StrokeLine(BPoint(160,10),BPoint(160,230),B_SOLID_HIGH);
|
||||
fBox->StrokeLine(BPoint(161,11),BPoint(161,230),B_SOLID_LOW);
|
||||
//Draw the icons
|
||||
fBox->DrawBitmap(fDoubleClickBitmap,BPoint(341,20));
|
||||
fBox->DrawBitmap(fSpeedBitmap,BPoint(331,90));
|
||||
fBox->DrawBitmap(fAccelerationBitmap,BPoint(331,155));
|
||||
fBox->StrokeLine(BPoint(156,10),BPoint(156,230),B_SOLID_HIGH);
|
||||
fBox->StrokeLine(BPoint(157,11),BPoint(157,230),B_SOLID_LOW);
|
||||
// Draw the icons
|
||||
fBox->DrawBitmap(fDoubleClickBitmap,BPoint(344,16));
|
||||
fBox->DrawBitmap(fSpeedBitmap,BPoint(333,90));
|
||||
fBox->DrawBitmap(fAccelerationBitmap,BPoint(333,155));
|
||||
|
||||
fBox->SetDrawingMode(B_OP_OVER);
|
||||
|
||||
// Draw the mouse top
|
||||
fBox->DrawBitmap(fMouseBitmap,BPoint(50, 41));
|
||||
int32 index = mouseTypeMenu->IndexOf(mouseTypeMenu->FindMarked());
|
||||
if (index == 0) { // 1 button
|
||||
if (fButtons & fCurrentMouseMap.button[0]) {
|
||||
fBox->DrawBitmap(fMouseDownBitmap,BPoint(50, 47));
|
||||
fBox->SetHighColor(64,64,64);
|
||||
}
|
||||
} else if (index == 1) { // 2 button
|
||||
if ( fButtons & fCurrentMouseMap.button[0]) {
|
||||
fBox->DrawBitmap(fMouseDownBitmap, BRect(0,0,27,28), BRect(50,47,77,75));
|
||||
fBox->SetHighColor(120,120,120);
|
||||
} else
|
||||
fBox->SetHighColor(184,184,184);
|
||||
fBox->StrokeLine(BPoint(76,49),BPoint(76,71),B_SOLID_HIGH);
|
||||
|
||||
if (fButtons & fCurrentMouseMap.button[1]) {
|
||||
fBox->SetHighColor(120,120,120);
|
||||
fBox->DrawBitmap(fMouseDownBitmap, BRect(27,0,54,28), BRect(77,47,104,75));
|
||||
} else
|
||||
fBox->SetHighColor(255,255,255);
|
||||
fBox->StrokeLine(BPoint(78,49),BPoint(78,71),B_SOLID_HIGH);
|
||||
|
||||
if ((fButtons & fCurrentMouseMap.button[0]) || (fButtons & fCurrentMouseMap.button[1]))
|
||||
fBox->SetHighColor(48,48,48);
|
||||
else
|
||||
fBox->SetHighColor(88,88,88);
|
||||
fBox->StrokeLine(BPoint(77,48),BPoint(77,72),B_SOLID_HIGH);
|
||||
|
||||
} else { // 3 button
|
||||
if ( fButtons & fCurrentMouseMap.button[0]) {
|
||||
fBox->DrawBitmap(fMouseDownBitmap, BRect(0,0,18,28), BRect(50,47,68,75));
|
||||
fBox->SetHighColor(120,120,120);
|
||||
} else
|
||||
fBox->SetHighColor(184,184,184);
|
||||
fBox->StrokeLine(BPoint(67,49),BPoint(67,71),B_SOLID_HIGH);
|
||||
|
||||
if (fButtons & fCurrentMouseMap.button[2]) {
|
||||
fBox->DrawBitmap(fMouseDownBitmap, BRect(18,0,36,28), BRect(68,47,86,75));
|
||||
fBox->SetHighColor(120,120,120);
|
||||
} else
|
||||
fBox->SetHighColor(184,184,184);
|
||||
fBox->StrokeLine(BPoint(85,49),BPoint(85,71),B_SOLID_HIGH);
|
||||
|
||||
if (fButtons & fCurrentMouseMap.button[2])
|
||||
fBox->SetHighColor(120,120,120);
|
||||
else
|
||||
fBox->SetHighColor(255,255,255);
|
||||
fBox->StrokeLine(BPoint(69,49),BPoint(69,71),B_SOLID_HIGH);
|
||||
|
||||
if (fButtons & fCurrentMouseMap.button[1]) {
|
||||
fBox->DrawBitmap(fMouseDownBitmap, BRect(36,0,54,28), BRect(86,47,104,75));
|
||||
fBox->SetHighColor(120,120,120);
|
||||
} else
|
||||
fBox->SetHighColor(255,255,255);
|
||||
fBox->StrokeLine(BPoint(87,49),BPoint(87,71),B_SOLID_HIGH);
|
||||
|
||||
if ((fButtons & fCurrentMouseMap.button[0]) || (fButtons & fCurrentMouseMap.button[2]))
|
||||
fBox->SetHighColor(48,48,48);
|
||||
else
|
||||
fBox->SetHighColor(88,88,88);
|
||||
fBox->StrokeLine(BPoint(68,48),BPoint(68,72),B_SOLID_HIGH);
|
||||
|
||||
if ((fButtons & fCurrentMouseMap.button[2]) || (fButtons & fCurrentMouseMap.button[1]))
|
||||
fBox->SetHighColor(48,48,48);
|
||||
else
|
||||
fBox->SetHighColor(88,88,88);
|
||||
fBox->StrokeLine(BPoint(86,48),BPoint(86,72),B_SOLID_HIGH);
|
||||
|
||||
}
|
||||
|
||||
fBox->SetHighColor(32,32,32);
|
||||
fBox->SetFont(be_plain_font);
|
||||
for(int32 i=0; i<index+1; i++) {
|
||||
char number[2] = "1";
|
||||
switch (fCurrentMouseMap.button[i]) {
|
||||
case B_PRIMARY_MOUSE_BUTTON: *number = '1'; break;
|
||||
case B_SECONDARY_MOUSE_BUTTON: *number = '2'; break;
|
||||
case B_TERTIARY_MOUSE_BUTTON: *number = '3'; break;
|
||||
}
|
||||
int32 offsets[][3] = { {75},
|
||||
{61, 88},
|
||||
{57, 92, 74} };
|
||||
fBox->MovePenTo(offsets[index][i], 65);
|
||||
fBox->DrawString(number);
|
||||
}
|
||||
|
||||
fBox->SetDrawingMode(B_OP_COPY);
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
MouseView::Init()
|
||||
{
|
||||
int32 value;
|
||||
// slow = 1000000, fast = 0
|
||||
value = (int32) ((1000000 - fClickSpeed) / 1000);
|
||||
if (value > 1000) value = 1000;
|
||||
if (value < 0) value = 0;
|
||||
dcSpeedSlider->SetValue(value);
|
||||
|
||||
// slow = 8192, fast = 524287
|
||||
value = (int32) (( log(fMouseSpeed / 8192) / log(2)) * 1000 / 6);
|
||||
if (value > 1000) value = 1000;
|
||||
if (value < 0) value = 0;
|
||||
mouseSpeedSlider->SetValue(value);
|
||||
|
||||
// slow = 0, fast = 262144
|
||||
value = (int32) (sqrt(fMouseAcc / 16384) * 1000 / 4);
|
||||
if (value > 1000) value = 1000;
|
||||
if (value < 0) value = 0;
|
||||
mouseAccSlider->SetValue(value);
|
||||
|
||||
if (fMouseType < 1)
|
||||
fMouseType = 1;
|
||||
if (fMouseType > 3)
|
||||
fMouseType = 3;
|
||||
BMenuItem *item = mouseTypeMenu->ItemAt(fMouseType - 1);
|
||||
if (item)
|
||||
item->SetMarked(true);
|
||||
|
||||
int32 mode;
|
||||
switch(fMouseMode) {
|
||||
case B_NORMAL_MOUSE: mode = 0; break;
|
||||
case B_FOCUS_FOLLOWS_MOUSE: mode = 1; break;
|
||||
case B_WARP_MOUSE: mode = 2; break;
|
||||
case B_INSTANT_WARP_MOUSE: mode = 3; break;
|
||||
default : mode = 0; break;
|
||||
}
|
||||
item = focusMenu->ItemAt(mode);
|
||||
if (item)
|
||||
item->SetMarked(true);
|
||||
|
||||
printf("click_speed : %lli, mouse_speed : %li, mouse_acc : %li, mouse_type : %li\n",
|
||||
fClickSpeed, fMouseSpeed, fMouseAcc, fMouseType);
|
||||
}
|
@ -1,14 +1,25 @@
|
||||
/*
|
||||
|
||||
MouseView.h
|
||||
|
||||
*/
|
||||
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: MouseView.h
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
#ifndef MOUSE_VIEW_H
|
||||
#define MOUSE_VIEW_H
|
||||
|
||||
#include <Box.h>
|
||||
#include <Bitmap.h>
|
||||
#include <Button.h>
|
||||
#include <Slider.h>
|
||||
#include <PopUpMenu.h>
|
||||
|
||||
class MouseView : public BBox
|
||||
{
|
||||
@ -16,14 +27,41 @@ public:
|
||||
typedef BBox inherited;
|
||||
|
||||
MouseView(BRect frame);
|
||||
void AttachedToWindow();
|
||||
virtual void Draw(BRect frame);
|
||||
|
||||
private:
|
||||
BBox *fBox;
|
||||
virtual void Pulse();
|
||||
void Init();
|
||||
|
||||
BButton *defaultButton, *revertButton;
|
||||
BSlider *dcSpeedSlider, *mouseSpeedSlider, *mouseAccSlider;
|
||||
BPopUpMenu *mouseTypeMenu, *focusMenu, *mouseMapMenu;
|
||||
|
||||
bigtime_t fClickSpeed;
|
||||
int32 fMouseSpeed;
|
||||
int32 fMouseAcc;
|
||||
int32 fMouseType;
|
||||
mode_mouse fMouseMode;
|
||||
mouse_map fMouseMap, fCurrentMouseMap;
|
||||
int32 fCurrentButton;
|
||||
uint32 fButtons;
|
||||
uint32 fOldButtons;
|
||||
|
||||
private:
|
||||
BBox *fBox;
|
||||
|
||||
BBitmap *fDoubleClickBitmap, *fSpeedBitmap, *fAccelerationBitmap;
|
||||
BBitmap *fMouseBitmap, *fMouseDownBitmap;
|
||||
|
||||
BBitmap *fDoubleClickBitmap;
|
||||
BBitmap *fSpeedBitmap;
|
||||
BBitmap *fAccelerationBitmap;
|
||||
};
|
||||
|
||||
class BoxView : public BBox
|
||||
{
|
||||
public:
|
||||
BoxView(BRect frame, MouseView *mouseView);
|
||||
void MouseDown(BPoint where);
|
||||
private:
|
||||
MouseView *fMouseView;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
|
@ -1,9 +1,18 @@
|
||||
/*
|
||||
* MouseWindow.cpp
|
||||
* Mouse mccall@digitalparadise.co.uk
|
||||
*
|
||||
*/
|
||||
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: MouseWindow.cpp
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
#include <Alert.h>
|
||||
#include <Application.h>
|
||||
#include <Message.h>
|
||||
#include <Screen.h>
|
||||
@ -12,74 +21,28 @@
|
||||
#include <Menu.h>
|
||||
#include <MenuItem.h>
|
||||
#include <MenuField.h>
|
||||
#include <Beep.h>
|
||||
#include <Debug.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "MouseMessages.h"
|
||||
#include "MouseWindow.h"
|
||||
#include "MouseView.h"
|
||||
#include "Mouse.h"
|
||||
|
||||
#define MOUSE_WINDOW_RIGHT 397
|
||||
#define MOUSE_WINDOW_BOTTTOM 293
|
||||
|
||||
MouseWindow::MouseWindow()
|
||||
: BWindow(BRect(0,0,MOUSE_WINDOW_RIGHT,MOUSE_WINDOW_BOTTTOM), "Mouse", B_TITLED_WINDOW, B_NOT_RESIZABLE | B_NOT_ZOOMABLE )
|
||||
MouseWindow::MouseWindow(BRect rect)
|
||||
: BWindow(rect, "Mouse", B_TITLED_WINDOW, B_NOT_RESIZABLE | B_NOT_ZOOMABLE )
|
||||
{
|
||||
BScreen screen;
|
||||
BSlider *slider=NULL;
|
||||
BMenuField *menufield=NULL;
|
||||
|
||||
MoveTo(dynamic_cast<MouseApplication *>(be_app)->WindowCorner());
|
||||
|
||||
// Code to make sure that the window doesn't get drawn off screen...
|
||||
if (!(screen.Frame().right >= Frame().right && screen.Frame().bottom >= Frame().bottom))
|
||||
MoveTo((screen.Frame().right-Bounds().right)*.5,(screen.Frame().bottom-Bounds().bottom)*.5);
|
||||
|
||||
BuildView();
|
||||
AddChild(fView);
|
||||
|
||||
|
||||
menufield = (BMenuField *)FindView("mouse_type");
|
||||
if (menufield !=NULL)
|
||||
menufield->Menu()->ItemAt((dynamic_cast<MouseApplication *>(be_app)->MouseType())-1)->SetMarked(true);
|
||||
|
||||
slider = (BSlider *)FindView("double_click_speed");
|
||||
if (slider !=NULL) slider->SetValue((dynamic_cast<MouseApplication *>(be_app)->ClickSpeed()));
|
||||
|
||||
slider = (BSlider *)FindView("mouse_speed");
|
||||
if (slider !=NULL) slider->SetValue((dynamic_cast<MouseApplication *>(be_app)->MouseSpeed()));
|
||||
Show();
|
||||
|
||||
AddChild(fView = new MouseView(Bounds()));
|
||||
if(fSettings.InitCheck() != B_OK)
|
||||
PostMessage(ERROR_DETECTED);
|
||||
SetPulseRate(100000);
|
||||
}
|
||||
|
||||
void
|
||||
MouseWindow::BuildView()
|
||||
{
|
||||
fView = new MouseView(Bounds());
|
||||
}
|
||||
|
||||
bool
|
||||
MouseWindow::QuitRequested()
|
||||
{
|
||||
|
||||
BSlider *slider=NULL;
|
||||
BMenuField *menufield=NULL;
|
||||
|
||||
dynamic_cast<MouseApplication *>(be_app)->SetWindowCorner(BPoint(Frame().left,Frame().top));
|
||||
|
||||
slider = (BSlider *)FindView("double_click_speed");
|
||||
if (slider !=NULL)
|
||||
dynamic_cast<MouseApplication *>(be_app)->SetClickSpeed(slider->Value());
|
||||
|
||||
|
||||
|
||||
menufield = (BMenuField *)FindView("mouse_type");
|
||||
if (menufield !=NULL) {
|
||||
BMenu *menu;
|
||||
menu = menufield->Menu();
|
||||
dynamic_cast<MouseApplication *>(be_app)->SetMouseType((mouse_type)(menu->IndexOf(menu->FindMarked())+1));
|
||||
}
|
||||
|
||||
fSettings.SetWindowCorner(Frame().LeftTop());
|
||||
|
||||
be_app->PostMessage(B_QUIT_REQUESTED);
|
||||
return(true);
|
||||
}
|
||||
@ -87,30 +50,109 @@ MouseWindow::QuitRequested()
|
||||
void
|
||||
MouseWindow::MessageReceived(BMessage *message)
|
||||
{
|
||||
BSlider *slider=NULL;
|
||||
BButton *button=NULL;
|
||||
BMenuField *menufield=NULL;
|
||||
|
||||
|
||||
switch(message->what) {
|
||||
case BUTTON_DEFAULTS: {
|
||||
if (set_click_speed(500000)!=B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
slider = (BSlider *)FindView("double_click_speed");
|
||||
if (slider !=NULL) slider->SetValue(500000);
|
||||
fView->dcSpeedSlider->SetValue(500);
|
||||
fView->dcSpeedSlider->Invoke();
|
||||
fView->mouseSpeedSlider->SetValue(500);
|
||||
fView->mouseSpeedSlider->Invoke();
|
||||
fView->mouseAccSlider->SetValue(500);
|
||||
fView->mouseAccSlider->Invoke();
|
||||
fView->focusMenu->ItemAt(0)->SetMarked(true);
|
||||
set_mouse_type(3);
|
||||
fView->mouseTypeMenu->ItemAt(2)->SetMarked(true);
|
||||
set_mouse_mode(B_NORMAL_MOUSE);
|
||||
fView->fCurrentMouseMap.button[0] = B_PRIMARY_MOUSE_BUTTON;
|
||||
fView->fCurrentMouseMap.button[1] = B_SECONDARY_MOUSE_BUTTON;
|
||||
fView->fCurrentMouseMap.button[2] = B_TERTIARY_MOUSE_BUTTON;
|
||||
set_mouse_map(&fView->fCurrentMouseMap);
|
||||
|
||||
button = (BButton *)FindView("mouse_revert");
|
||||
if (button !=NULL) button->SetEnabled(true);
|
||||
fView->revertButton->SetEnabled(true);
|
||||
}
|
||||
break;
|
||||
case BUTTON_REVERT: {
|
||||
fView->Init();
|
||||
set_mouse_type(fView->fMouseType);
|
||||
set_mouse_mode(fView->fMouseMode);
|
||||
set_click_speed(fView->fClickSpeed);
|
||||
set_mouse_speed(fView->fMouseSpeed);
|
||||
set_mouse_acceleration(fView->fMouseAcc);
|
||||
set_mouse_map(&fView->fMouseMap);
|
||||
get_mouse_map(&fView->fCurrentMouseMap);
|
||||
|
||||
fView->revertButton->SetEnabled(false);
|
||||
}
|
||||
break;
|
||||
case POPUP_MOUSE_TYPE: {
|
||||
beep();
|
||||
menufield = (BMenuField *)FindView("mouse_type");
|
||||
if (menufield !=NULL) {
|
||||
BMenu *menu;
|
||||
menu = menufield->Menu();
|
||||
if (set_mouse_type(menu->IndexOf(menu->FindMarked())+1) !=B_OK)
|
||||
be_app->PostMessage(ERROR_DETECTED);
|
||||
status_t err = set_mouse_type(fView->mouseTypeMenu->IndexOf(fView->mouseTypeMenu->FindMarked())+1);
|
||||
if(err < B_OK)
|
||||
printf("error while setting mouse type : %s\n", strerror(err));
|
||||
fView->revertButton->SetEnabled(true);
|
||||
}
|
||||
break;
|
||||
case POPUP_MOUSE_FOCUS: {
|
||||
mode_mouse mouse_mode = B_NORMAL_MOUSE;
|
||||
switch (fView->focusMenu->IndexOf(fView->focusMenu->FindMarked())) {
|
||||
case 0: mouse_mode = B_NORMAL_MOUSE; break;
|
||||
case 1: mouse_mode = B_FOCUS_FOLLOWS_MOUSE; break;
|
||||
case 2: mouse_mode = B_WARP_MOUSE; break;
|
||||
case 3: mouse_mode = B_INSTANT_WARP_MOUSE; break;
|
||||
}
|
||||
set_mouse_mode(mouse_mode);
|
||||
fView->revertButton->SetEnabled(true);
|
||||
}
|
||||
break;
|
||||
case SLIDER_DOUBLE_CLICK_SPEED: {
|
||||
int32 value = fView->dcSpeedSlider->Value();
|
||||
int32 click_speed; // slow = 1000000, fast = 0
|
||||
click_speed = (int32) (1000000 - value * 1000);
|
||||
status_t err = set_click_speed(click_speed);
|
||||
if(err < B_OK)
|
||||
printf("error while setting click speed : %s\n", strerror(err));
|
||||
fView->revertButton->SetEnabled(true);
|
||||
}
|
||||
break;
|
||||
case SLIDER_MOUSE_SPEED: {
|
||||
int32 value = fView->mouseSpeedSlider->Value();
|
||||
int32 mouse_speed; // slow = 8192, fast = 524287
|
||||
mouse_speed = (int32) pow(2, value * 6 / 1000) * 8192;
|
||||
status_t err = set_mouse_speed(mouse_speed);
|
||||
if(err < B_OK)
|
||||
printf("error while setting mouse speed : %s\n", strerror(err));
|
||||
fView->revertButton->SetEnabled(true);
|
||||
}
|
||||
break;
|
||||
case SLIDER_MOUSE_ACC: {
|
||||
int32 value = fView->mouseAccSlider->Value();
|
||||
int32 mouse_acc; // slow = 0, fast = 262144
|
||||
mouse_acc = (int32) pow(value * 4 / 1000, 2) * 16384;
|
||||
status_t err = set_mouse_acceleration(mouse_acc);
|
||||
if(err < B_OK)
|
||||
printf("error while setting mouse acceleration : %s\n", strerror(err));
|
||||
fView->revertButton->SetEnabled(true);
|
||||
}
|
||||
break;
|
||||
case POPUP_MOUSE_MAP: {
|
||||
int32 index = fView->mouseMapMenu->IndexOf(fView->mouseMapMenu->FindMarked());
|
||||
int32 number = B_PRIMARY_MOUSE_BUTTON;
|
||||
switch (index) {
|
||||
case 0: number = B_PRIMARY_MOUSE_BUTTON; break;
|
||||
case 1: number = B_SECONDARY_MOUSE_BUTTON; break;
|
||||
case 2: number = B_TERTIARY_MOUSE_BUTTON; break;
|
||||
}
|
||||
fView->fCurrentMouseMap.button[fView->fCurrentButton] = number;
|
||||
status_t err = set_mouse_map(&fView->fCurrentMouseMap);
|
||||
fView->fCurrentButton = -1;
|
||||
if(err < B_OK)
|
||||
printf("error while setting mouse map : %s\n", strerror(err));
|
||||
fView->revertButton->SetEnabled(true);
|
||||
}
|
||||
break;
|
||||
case ERROR_DETECTED: {
|
||||
(new BAlert("Error", "Something has gone wrong!","OK",NULL,NULL,
|
||||
B_WIDTH_AS_USUAL, B_OFFSET_SPACING, B_WARNING_ALERT))->Go();
|
||||
be_app->PostMessage(B_QUIT_REQUESTED);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
@ -119,8 +161,3 @@ MouseWindow::MessageReceived(BMessage *message)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
MouseWindow::~MouseWindow()
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -1,3 +1,17 @@
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
//
|
||||
// Copyright (c) 2003, OpenBeOS
|
||||
//
|
||||
// This software is part of the OpenBeOS distribution and is covered
|
||||
// by the OpenBeOS license.
|
||||
//
|
||||
//
|
||||
// File: MouseWindow.h
|
||||
// Author: Jérôme Duval, Andrew McCall (mccall@digitalparadise.co.uk)
|
||||
// Description: Media Preferences
|
||||
// Created : December 10, 2003
|
||||
//
|
||||
// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
|
||||
#ifndef MOUSE_WINDOW_H
|
||||
#define MOUSE_WINDOW_H
|
||||
|
||||
@ -9,16 +23,14 @@
|
||||
class MouseWindow : public BWindow
|
||||
{
|
||||
public:
|
||||
MouseWindow();
|
||||
~MouseWindow();
|
||||
MouseWindow(BRect rect);
|
||||
|
||||
bool QuitRequested();
|
||||
void MessageReceived(BMessage *message);
|
||||
void BuildView();
|
||||
|
||||
|
||||
MouseSettings fSettings;
|
||||
private:
|
||||
MouseView *fView;
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user