forked from HaikuArchives/sanity
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Sanity.h
48 lines (37 loc) · 1.05 KB
/
Sanity.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#ifndef SANITY_H
#define SANITY_H
#include <Application.h>
#include <Window.h>
#include "ScannerWindow.h"
#define SOFTWARE_EDITOR "prds"
#define SOFTWARE_NAME "Sanity"
#define SOFTWARE_VERSION_LABEL "0.6"
#define SANE_MIMETYPE "image/x-vnd.sane-scanner-wrapper"
class Application : public BApplication
{
public:
// Constructors, destructors, operators...
Application();
~Application();
typedef BApplication inherited;
// public constantes
enum {
NEW_WINDOW_MSG = 'neww',
WINDOW_CLOSED_MSG = 'wcls'
};
public:
// Virtual function overrides
virtual void MessageReceived(BMessage * msg);
virtual void RefsReceived(BMessage * msg);
virtual void AboutRequested();
// bool QuitRequested(void);
void ReadyToRun(void);
// From here, it's none of your business! ;-)
private:
void OpenSaneWrapper(BString dev);
ScannerWindow * m_window;
BString m_device;
};
// open a BFile to the binary which code is pointed to by ptr
extern status_t GetBinaryPath(char *path, void *ptr);
#endif // ifdef SANITY_H