added a skeleton for Installer

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14212 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Jérôme Duval 2005-09-20 15:44:08 +00:00
parent 975cd0c019
commit 6ffb6a6e04
7 changed files with 213 additions and 0 deletions

View File

@ -9,6 +9,7 @@ SubInclude OBOS_TOP src apps deskbar ;
SubInclude OBOS_TOP src apps diskprobe ;
SubInclude OBOS_TOP src apps expander ;
SubInclude OBOS_TOP src apps glteapot ;
SubInclude OBOS_TOP src apps installer ;
SubInclude OBOS_TOP src apps magnify ;
#SubInclude OBOS_TOP src apps mediaplayer ;
SubInclude OBOS_TOP src apps midiplayer ;

View File

@ -0,0 +1,66 @@
resource large_icon
{
$"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF"
$"FFFFFFFFFFFFFFFFFFFF000000FFFFFF00FFFFFFFFFFFFFFFFFFFFFFFFFFFFFF"
$"FFFFFFFFFFFFFFFFFF00BEBEBE0000000A0000FFFFFFFFFFFFFFFFFFFFFFFFFF"
$"FFFFFFFFFFFFFFFF00BEBEBEBEBE000A0B04000000FFFFFFFFFFFFFFFFFFFFFF"
$"FFFFFFFFFFFFFF00BEBEBEBEBE000A0B04002D2E2D0000FFFFFFFFFFFFFFFFFF"
$"FFFFFFFFFFFF00BEBEBEBEBE000A0B04003F3F2D2E2DD20000FFFFFFFFFFFFFF"
$"FFFFFFFFFF00BEBEBEBEBE000A0B04003F3F3F3F3FD2D2D2D20000FFFFFFFFFF"
$"FFFFFFFF00BEBEBEBEBE000A0B04003F3F3F3F3F3F3F3FD2D2D2D20000FFFFFF"
$"FFFFFF00BEBEBEBEBE000A0B04003F3F3F3F3F3F3F3F3F3F3FD2D200170000FF"
$"FF000026BEBEBEBE000A0B0A0B1700003F3F3F3F3F3F3F3F3F3F00170B0A0B00"
$"001111252625BE000A0B0B0A0B0B171700003F3F3F3F3F3F3F00170B0A0B0400"
$"001104051111000A0B0A0B0B0A0B0B0A181700003F3F3F3F00170B0A0B040400"
$"0011050411000A0B0B0A1600000A0B0A0B0B171700003F00170B0A0B040400FF"
$"001104BE000A0B0B0A1600171700000B0B0A0B0A181700180A0B0A050400FFFF"
$"00110425003F3F0A15001817040B1700000B0B0A0B0B170B0A0B040400FFFFFF"
$"0011041B0016153F00171705000417181700000B0A0B0A0B0B040400FFFFFFFF"
$"0011040F0F000015003F3F0004171817171817000B0A0B0B040400FFFFFFFFFF"
$"0011041B0F0F15000016153F3F171718171700180A0B0B040400FFFFFFFFFFFF"
$"0011040F1B1C0F0F15000015153F3F171700180A0B0B0404000F0F0FFFFFFFFF"
$"001104270F0F1B1C0F0A18000015153F00170B0A0B0404000F0F0F0F0F0FFFFF"
$"0011042517180E0F0F0B170403000015003F3F0A0405000F0E0F0F0F0F0F0FFF"
$"00110404252417270F0B170502262400001515040000000000000000000F0F0F"
$"0011040504042524270B17040226242525000005007D5D5DF9F9F97D000F0F0F"
$"0011040411040504250B17040325252524250000005D5DF9F9F97D7D000E0F0F"
$"0011040511041104040B1705022525252524000F003FF9F9F9F900000E0F0FFF"
$"0011040411041105040A18040225252524000F0F003FF9F93FF9F9F90000FFFF"
$"0000000011041104040B170502252525000F0E0F003F7D7D5D3F3FF9F9F900FF"
$"FFFFFFFF00001104040B1704022525000F0F0F0F007D7D7D5D5D5D3FF97D000E"
$"FFFFFFFFFFFF0000040A18040225000F0F0F0F0F007D7D00005D5D5D7D7D000E"
$"FFFFFFFFFFFFFFFF000A180402000F0F0F0E0FFF007D000E0F00005D7D000F0F"
$"FFFFFFFFFFFFFFFFFF001704000F0F0F0F0FFFFFFF000E0F0FFFFF00000E0FFF"
$"FFFFFFFFFFFFFFFFFFFF00000E0F0F0F0FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF"
};
resource mini_icon
{
$"FFFFFFFF000000FF00FFFFFFFFFFFFFF"
$"FFFFFF00BEBE0000000000FFFFFFFFFF"
$"FFFF00BEBEBE0004002D2E0000FFFFFF"
$"FF00BEBEBE0004003F3FD2D2D20000FF"
$"00BEBEBE000A00003F3F3F3FD2D20000"
$"001111000A0B0A0B00003F3F0A0B0400"
$"0011000B0A00000B0B0A000B0A050000"
$"0011000A003F1700000B0A0B040000FF"
$"0011000015153F3F17000B040000FFFF"
$"0011252500001515290B0400000F0FFF"
$"00112525112500000A0400000000000F"
$"00110504112527250000005DF97D000E"
$"0011050411252726000F00F9F901000E"
$"FF000004B22626000F0F007D5DF97D00"
$"FFFFFF000026000E0F0F2900007D7D00"
$"FFFFFFFFFF000E0FFFFF000E0F00000F"
};
resource app_signature "application/x-vnd.haiku-Installer";
resource app_version
{
short_info = "Haiku Installer",
long_info = "Haiku version of Installer"
};
resource app_flags B_EXCLUSIVE_LAUNCH;

View File

@ -0,0 +1,53 @@
/*
* Copyright 2005, Jérôme DUVAL. All rights reserved.
* Distributed under the terms of the MIT License.
*/
#include <Alert.h>
#include <TextView.h>
#include "InstallerApp.h"
const char *APP_SIG = "application/x-vnd.haiku-Installer";
int main(int, char **)
{
InstallerApp theApp;
theApp.Run();
return 0;
}
InstallerApp::InstallerApp()
: BApplication(APP_SIG)
{
BRect windowFrame(0,0,332,160);
windowFrame.OffsetBy(154,87);
fWindow = new InstallerWindow(windowFrame);
}
void
InstallerApp::AboutRequested()
{
BAlert *alert = new BAlert("about", "Installer\n"
"\twritten by Jérôme Duval\n"
"\tCopyright 2005, Haiku.\n\n", "Ok");
BTextView *view = alert->TextView();
BFont font;
view->SetStylable(true);
view->GetFont(&font);
font.SetSize(18);
font.SetFace(B_BOLD_FACE);
view->SetFontAndColor(0, 14, &font);
alert->Go();
}
void
InstallerApp::ReadyToRun()
{
}

View File

@ -0,0 +1,24 @@
/*
* Copyright 2005, Jérôme DUVAL. All rights reserved.
* Distributed under the terms of the MIT License.
*/
#ifndef _InstallerApp_h
#define _InstallerApp_h
#include <Application.h>
#include "InstallerWindow.h"
class InstallerApp : public BApplication {
public:
InstallerApp();
public:
virtual void AboutRequested();
virtual void ReadyToRun();
private:
InstallerWindow *fWindow;
};
#endif /* _InstallerApp_h */

View File

@ -0,0 +1,39 @@
/*
* Copyright 2005, Jérôme DUVAL. All rights reserved.
* Distributed under the terms of the MIT License.
*/
#include <Application.h>
#include <Box.h>
#include "InstallerWindow.h"
InstallerWindow::InstallerWindow(BRect frame_rect)
: BWindow(frame_rect, "Installer", B_TITLED_WINDOW, B_NOT_ZOOMABLE | B_NOT_RESIZABLE)
{
// finish creating window
Show();
}
InstallerWindow::~InstallerWindow()
{
}
void
InstallerWindow::MessageReceived(BMessage *msg)
{
switch (msg->what) {
default:
BWindow::MessageReceived(msg);
break;
}
}
bool
InstallerWindow::QuitRequested()
{
be_app->PostMessage(B_QUIT_REQUESTED);
return true;
}

View File

@ -0,0 +1,22 @@
/*
* Copyright 2005, Jérôme DUVAL. All rights reserved.
* Distributed under the terms of the MIT License.
*/
#ifndef _InstallerWindow_h
#define _InstallerWindow_h
#include <Window.h>
class InstallerWindow : public BWindow {
public:
InstallerWindow(BRect frameRect);
virtual ~InstallerWindow();
virtual void MessageReceived(BMessage *msg);
virtual bool QuitRequested();
private:
};
#endif /* _InstallerWindow_h */

View File

@ -0,0 +1,8 @@
SubDir OBOS_TOP src apps installer ;
App Installer :
InstallerApp.cpp
InstallerWindow.cpp
: libbe.so
: Installer.rdef ;