WIP: Menubar and Popup's

git-svn-id: svn://10.0.0.236/trunk@7414 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
spider%netscape.com 1998-08-06 01:23:37 +00:00
parent 2f5b521dac
commit 702a43e7f8
14 changed files with 331 additions and 2 deletions

View File

@ -17,7 +17,7 @@
DEPTH = ..
DIRS = public src tests
DIRS = public inc src tests
include $(DEPTH)/config/config.mk

View File

@ -0,0 +1,29 @@
#!gmake
#
# The contents of this file are subject to the Netscape Public License
# Version 1.0 (the "NPL"); you may not use this file except in
# compliance with the NPL. You may obtain a copy of the NPL at
# http://www.mozilla.org/NPL/
#
# Software distributed under the NPL is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
# for the specific language governing rights and limitations under the
# NPL.
#
# The Initial Developer of this code under the NPL is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All Rights
# Reserved.
DEPTH = ../..
MODULE = shell
EXPORTS = \
nsMenuBar.h \
nsMenuItem.h \
$(NULL)
include $(DEPTH)/config/config.mk
include $(DEPTH)/config/rules.mk

View File

@ -0,0 +1,30 @@
#!nmake
#
# The contents of this file are subject to the Netscape Public License
# Version 1.0 (the "NPL"); you may not use this file except in
# compliance with the NPL. You may obtain a copy of the NPL at
# http://www.mozilla.org/NPL/
#
# Software distributed under the NPL is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
# for the specific language governing rights and limitations under the
# NPL.
#
# The Initial Developer of this code under the NPL is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All Rights
# Reserved.
DEPTH=..\..
IGNORE_MANIFEST=1
MODULE=shell
EXPORTS = \
nsMenuBar.h \
nsMenuItem.h \
$(NULL)
include <$(DEPTH)\config\rules.mak>

View File

@ -0,0 +1,48 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
#include "nsIMenuBar.h"
class nsMenuBar : public nsIMenuBar
{
public:
/**
* Constructor and Destructor
*/
nsMenuBar();
~nsMenuBar();
/**
* ISupports Interface
*/
NS_DECL_ISUPPORTS
/**
* Initialize Method
* @result The result of the initialization, NS_OK if no errors
*/
NS_IMETHOD Init();
};

View File

@ -0,0 +1,48 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
#include "nsIMenuItem.h"
class nsMenuItem : public nsIMenuItem
{
public:
/**
* Constructor and Destructor
*/
nsMenuItem();
~nsMenuItem();
/**
* ISupports Interface
*/
NS_DECL_ISUPPORTS
/**
* Initialize Method
* @result The result of the initialization, NS_OK if no errors
*/
NS_IMETHOD Init();
};

View File

@ -18,6 +18,6 @@
DEPTH=..
IGNORE_MANIFEST=1
DIRS=public src tests
DIRS=public inc src tests
include <$(DEPTH)\config\rules.mak>

View File

@ -22,6 +22,8 @@ MODULE = shell
EXPORTS = \
nsIApplicationShell.h \
nsIShellInstance.h \
nsIMenuBar.h \
nsIMenuItem.h \
nsshell.h \
$(NULL)

View File

@ -24,6 +24,8 @@ MODULE=shell
EXPORTS = \
nsIApplicationShell.h \
nsIShellInstance.h \
nsIMenuBar.h \
nsIMenuItem.h \
nsshell.h \
$(NULL)

View File

@ -0,0 +1,44 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
#ifndef nsIMenuBar_h___
#define nsIMenuBar_h___
#include "nsISupports.h"
// 52fb95f0-2cbe-11d2-9246-00805f8a7ab6
#define NS_IMENUBAR_IID \
{ 0x52fb95f0, 0x2cbe, 0x11d2, \
{0x92, 0x46, 0x00, 0x80, 0x5f, 0x8a, 0x7a, 0xb6} }
class nsIMenuBar : public nsISupports
{
public:
/**
* Initialize the MenuBar
* @result The result of the initialization, NS_Ok if no errors
*/
NS_IMETHOD Init() = 0;
};
#endif /* nsIMenuBar_h___ */

View File

@ -0,0 +1,44 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
#ifndef nsIMenuItem_h___
#define nsIMenuItem_h___
#include "nsISupports.h"
// 8a400b00-2cbe-11d2-9246-00805f8a7ab6
#define NS_IMENUITEM_IID \
{ 0x8a400b00, 0x2cbe, 0x11d2, \
{0x92, 0x46, 0x00, 0x80, 0x5f, 0x8a, 0x7a, 0xb6} }
class nsIMenuItem : public nsISupports
{
public:
/**
* Initialize the MenuBar
* @result The result of the initialization, NS_Ok if no errors
*/
NS_IMETHOD Init() = 0;
};
#endif /* nsIMenuItem_h___ */

View File

@ -60,11 +60,15 @@ EXPORTS = \
CPPSRCS= \
nsApplicationManager.cpp \
nsShellInstance.cpp \
nsMenuItem.cpp \
nsMenuBar.cpp \
$(NULL)
CPP_OBJS= \
./$(OBJDIR)/nsApplicationManager.o \
./$(OBJDIR)/nsShellInstance.o \
./$(OBJDIR)/nsMenuItem.o \
./$(OBJDIR)/nsMenuBar.o \
$(NULL)

View File

@ -30,11 +30,15 @@ EXPORTS = \
CPPSRCS= \
nsApplicationManager.cpp \
nsShellInstance.cpp \
nsMenuBar.cpp \
nsMenuItem.cpp \
$(NULL)
CPP_OBJS= \
.\$(OBJDIR)\nsApplicationManager.obj \
.\$(OBJDIR)\nsShellInstance.obj \
.\$(OBJDIR)\nsMenuBar.obj \
.\$(OBJDIR)\nsMenuItem.obj \
$(NULL)
LINCS=-I$(PUBLIC)\xpcom -I$(PUBLIC)\raptor \

View File

@ -0,0 +1,37 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
#include "nscore.h"
#include "nsMenuBar.h"
nsMenuBar::nsMenuBar()
{
}
nsMenuBar::~nsMenuBar()
{
}
NS_DEFINE_IID(kIMenuBarIID, NS_IMENUBAR_IID);
NS_IMPL_ISUPPORTS(nsMenuBar,kIMenuBarIID);
nsresult nsMenuBar::Init()
{
return NS_OK;
}

View File

@ -0,0 +1,37 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
#include "nscore.h"
#include "nsMenuItem.h"
nsMenuItem::nsMenuItem()
{
}
nsMenuItem::~nsMenuItem()
{
}
NS_DEFINE_IID(kIMenuItemIID, NS_IMENUITEM_IID);
NS_IMPL_ISUPPORTS(nsMenuItem,kIMenuItemIID);
nsresult nsMenuItem::Init()
{
return NS_OK;
}