Removed any unnecessary cruft from NetworkWindow header and source, fixed style
issues. (Not actually tested.) git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37865 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1,11 +1,12 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2004-2008 Haiku Inc. All rights reserved.
|
* Copyright 2004-2010 Haiku Inc. All rights reserved.
|
||||||
* Distributed under the terms of the MIT License.
|
* Distributed under the terms of the MIT License.
|
||||||
*
|
*
|
||||||
* Author:
|
* Author:
|
||||||
* Andre Alves Garzia, [email protected]
|
* Andre Alves Garzia, [email protected]
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include "NetworkWindow.h"
|
#include "NetworkWindow.h"
|
||||||
|
|
||||||
#include <Application.h>
|
#include <Application.h>
|
||||||
@@ -15,39 +16,17 @@
|
|||||||
|
|
||||||
#include "EthernetSettingsView.h"
|
#include "EthernetSettingsView.h"
|
||||||
|
|
||||||
|
|
||||||
#undef B_TRANSLATE_CONTEXT
|
#undef B_TRANSLATE_CONTEXT
|
||||||
#define B_TRANSLATE_CONTEXT "NetworkWindow"
|
#define B_TRANSLATE_CONTEXT "NetworkWindow"
|
||||||
|
|
||||||
|
|
||||||
NetworkWindow::NetworkWindow()
|
NetworkWindow::NetworkWindow()
|
||||||
: BWindow(BRect(50, 50, 269, 302), B_TRANSLATE("Network"), B_TITLED_WINDOW,
|
:
|
||||||
|
BWindow(BRect(50, 50, 269, 302), B_TRANSLATE("Network"), B_TITLED_WINDOW,
|
||||||
B_NOT_RESIZABLE | B_ASYNCHRONOUS_CONTROLS | B_NOT_ZOOMABLE
|
B_NOT_RESIZABLE | B_ASYNCHRONOUS_CONTROLS | B_NOT_ZOOMABLE
|
||||||
| B_AUTO_UPDATE_SIZE_LIMITS)
|
| B_AUTO_UPDATE_SIZE_LIMITS | B_QUIT_ON_WINDOW_CLOSE)
|
||||||
{
|
{
|
||||||
SetLayout(new BGroupLayout(B_HORIZONTAL));
|
SetLayout(new BGroupLayout(B_HORIZONTAL));
|
||||||
fEthernetView = new EthernetSettingsView();
|
GetLayout()->AddView(new EthernetSettingsView());
|
||||||
GetLayout()->AddView(fEthernetView);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
NetworkWindow::~NetworkWindow()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void
|
|
||||||
NetworkWindow::MessageReceived(BMessage* message)
|
|
||||||
{
|
|
||||||
switch (message->what) {
|
|
||||||
default:
|
|
||||||
BWindow::MessageReceived(message);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool
|
|
||||||
NetworkWindow::QuitRequested()
|
|
||||||
{
|
|
||||||
be_app->PostMessage(B_QUIT_REQUESTED);
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2004-2008 Haiku Inc. All rights reserved.
|
* Copyright 2004-2010 Haiku Inc. All rights reserved.
|
||||||
* Distributed under the terms of the MIT License.
|
* Distributed under the terms of the MIT License.
|
||||||
*
|
*
|
||||||
* Author:
|
* Author:
|
||||||
@@ -11,18 +11,11 @@
|
|||||||
|
|
||||||
#include <Window.h>
|
#include <Window.h>
|
||||||
|
|
||||||
#include "EthernetSettingsView.h"
|
|
||||||
|
|
||||||
|
|
||||||
class NetworkWindow : public BWindow {
|
class NetworkWindow : public BWindow {
|
||||||
public:
|
public:
|
||||||
NetworkWindow();
|
NetworkWindow();
|
||||||
virtual ~NetworkWindow();
|
|
||||||
virtual bool QuitRequested();
|
|
||||||
virtual void MessageReceived(BMessage* mesage);
|
|
||||||
|
|
||||||
private:
|
|
||||||
EthernetSettingsView* fEthernetView;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* NETWORK_WINDOW_H */
|
|
||||||
|
#endif // NETWORK_WINDOW_H
|
||||||
|
|||||||
Reference in New Issue
Block a user