From b14b767dc04d24eafb468ab56fae9eede2c75942 Mon Sep 17 00:00:00 2001 From: "blizzard%redhat.com" Date: Fri, 15 Mar 2002 05:08:44 +0000 Subject: [PATCH] Get this code building and linking again after the Enable changes and the -symbolic changes. git-svn-id: svn://10.0.0.236/trunk@116624 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/widget/src/gtk2/Makefile.in | 7 ++++++- mozilla/widget/src/gtk2/nsCommonWidget.cpp | 17 +++++++++++++++++ mozilla/widget/src/gtk2/nsCommonWidget.h | 4 ++++ 3 files changed, 27 insertions(+), 1 deletion(-) diff --git a/mozilla/widget/src/gtk2/Makefile.in b/mozilla/widget/src/gtk2/Makefile.in index bc345955c0b..4e5919fdc1e 100644 --- a/mozilla/widget/src/gtk2/Makefile.in +++ b/mozilla/widget/src/gtk2/Makefile.in @@ -55,7 +55,12 @@ CPPSRCS = \ SHARED_LIBRARY_LIBS = $(DIST)/lib/libxpwidgets_s.a -EXTRA_DSO_LDOPTS += $(MOZ_GTK2_LIBS) +EXTRA_DSO_LDOPTS += \ + $(MOZ_COMPONENT_LIBS) \ + -lgkgfx \ + $(XLDFLAGS) \ + $(XLIBS) \ + $(MOZ_GTK2_LIBS) EXPORTS = \ mozdrawingarea.h \ diff --git a/mozilla/widget/src/gtk2/nsCommonWidget.cpp b/mozilla/widget/src/gtk2/nsCommonWidget.cpp index ed51e4b58a8..0d58196526f 100644 --- a/mozilla/widget/src/gtk2/nsCommonWidget.cpp +++ b/mozilla/widget/src/gtk2/nsCommonWidget.cpp @@ -48,6 +48,7 @@ nsCommonWidget::nsCommonWidget() mListenForResizes = PR_FALSE; mIsShown = PR_FALSE; mNeedsShow = PR_FALSE; + mEnabled = PR_TRUE; mPreferredWidth = 0; mPreferredHeight = 0; @@ -458,6 +459,22 @@ nsCommonWidget::SetPreferredSize(PRInt32 aWidth, return NS_OK; } +NS_IMETHODIMP +nsCommonWidget::Enable(PRBool aState) +{ + mEnabled = aState; + + return NS_OK; +} + +NS_IMETHODIMP +nsCommonWidget::IsEnabled(PRBool *aState) +{ + *aState = mEnabled; + + return NS_OK; +} + void nsCommonWidget::OnDestroy(void) { diff --git a/mozilla/widget/src/gtk2/nsCommonWidget.h b/mozilla/widget/src/gtk2/nsCommonWidget.h index 56087245c1e..399219178cc 100644 --- a/mozilla/widget/src/gtk2/nsCommonWidget.h +++ b/mozilla/widget/src/gtk2/nsCommonWidget.h @@ -109,6 +109,8 @@ class nsCommonWidget : public nsBaseWidget { PRInt32 &aHeight); NS_IMETHOD SetPreferredSize (PRInt32 aWidth, PRInt32 aHeight); + NS_IMETHOD Enable (PRBool aState); + NS_IMETHOD IsEnabled (PRBool *aState); // called when we are destroyed void OnDestroy(void); @@ -131,6 +133,8 @@ class nsCommonWidget : public nsBaseWidget { // This flag tracks if we're hidden or shown. PRPackedBool mIsShown; PRPackedBool mNeedsShow; + // is this widget enabled? + PRBool mEnabled; // Preferred sizes PRUint32 mPreferredWidth;