* Make use of the new svn revision jam magic to embed the current svn version

into the about window.
* Give access to the about window from the browser windows.
* Renamed the "Show *" entries in the Window menu to just "*".

git-svn-id: http://svn.haiku-os.org/webpositive/webkit/trunk@387 94f232f2-1747-11df-bad5-a5bfde151594
This commit is contained in:
stippi 2010-04-05 17:05:17 +00:00 committed by Alexandre Deckner
parent cb0b497952
commit 65e61cdca4
4 changed files with 36 additions and 5 deletions

View File

@ -34,6 +34,7 @@
#include "DownloadWindow.h" #include "DownloadWindow.h"
#include "SettingsMessage.h" #include "SettingsMessage.h"
#include "SettingsWindow.h" #include "SettingsWindow.h"
#include "svn_revision.h"
#include "NetworkCookieJar.h" #include "NetworkCookieJar.h"
#include "WebPage.h" #include "WebPage.h"
#include "WebSettings.h" #include "WebSettings.h"
@ -86,9 +87,11 @@ BrowserApp::~BrowserApp()
void void
BrowserApp::AboutRequested() BrowserApp::AboutRequested()
{ {
BAlert* alert = new BAlert("About WebPositive", BString aboutText("WebPositive\n\nby Ryan Leavengood, Andrea Anzani, "
"WebPositive\n\nby Ryan Leavengood, Andrea Anzani, " "Maxime Simone, Michael Lotz, Rene Gollent and Stephan Aßmus");
"Maxime Simone, Michael Lotz, Rene Gollent and Stephan Aßmus", aboutText << "\n\nSVN revision: " << kSVNRevision;
BAlert* alert = new BAlert("About WebPositive", aboutText.String(),
"Sweet!"); "Sweet!");
alert->Go(); alert->Go();
} }

View File

@ -273,8 +273,11 @@ BrowserWindow::BrowserWindow(BRect frame, ToolbarPolicy toolbarPolicy,
menu->AddItem(new BMenuItem("Close window", new BMessage(B_QUIT_REQUESTED), 'W', B_SHIFT_KEY)); menu->AddItem(new BMenuItem("Close window", new BMessage(B_QUIT_REQUESTED), 'W', B_SHIFT_KEY));
menu->AddItem(new BMenuItem("Close tab", new BMessage(CLOSE_TAB), 'W')); menu->AddItem(new BMenuItem("Close tab", new BMessage(CLOSE_TAB), 'W'));
menu->AddSeparatorItem(); menu->AddSeparatorItem();
menu->AddItem(new BMenuItem("Show downloads", new BMessage(SHOW_DOWNLOAD_WINDOW), 'J')); menu->AddItem(new BMenuItem("Downloads", new BMessage(SHOW_DOWNLOAD_WINDOW), 'J'));
menu->AddItem(new BMenuItem("Show settings", new BMessage(SHOW_SETTINGS_WINDOW))); menu->AddItem(new BMenuItem("Settings", new BMessage(SHOW_SETTINGS_WINDOW)));
BMenuItem* aboutItem = new BMenuItem("About", new BMessage(B_ABOUT_REQUESTED));
menu->AddItem(aboutItem);
aboutItem->SetTarget(be_app);
menu->AddSeparatorItem(); menu->AddSeparatorItem();
BMenuItem* quitItem = new BMenuItem("Quit", new BMessage(B_QUIT_REQUESTED), 'Q'); BMenuItem* quitItem = new BMenuItem("Quit", new BMessage(B_QUIT_REQUESTED), 'Q');
menu->AddItem(quitItem); menu->AddItem(quitItem);

View File

@ -0,0 +1,10 @@
/*
* Copyright 2006-2009, Ingo Weinhold <ingo_weinhold@gmx.de>
* All rights reserved. Distributed under the terms of the MIT License.
*/
#include "svn_revision.h"
const int32 kSVNRevision =
#include "svn_revision"
;

View File

@ -0,0 +1,15 @@
/*
* Copyright 2006-2009, Ingo Weinhold <ingo_weinhold@gmx.de>
* All rights reserved. Distributed under the terms of the MIT License.
*/
#ifndef SVN_REVISION_H
#define SVN_REVISION_H
#include <SupportDefs.h>
extern const int32 kSVNRevision;
#endif // SVN_REVISION_H