Mailinglist Archive: yast-commit (815 mails)
| < Previous | Next > |
[yast-commit] r39863 - in /branches/tmp/sh/mod-ui/ncurses/src: NCPopupTable.cc NCPopupTable.h
- From: gs@xxxxxxxxxxxxxxxx
- Date: Wed, 01 Aug 2007 10:06:30 -0000
- Message-id: <20070801100630.7C12926982@xxxxxxxxxxxxxxxx>
Author: gs
Date: Wed Aug 1 12:06:30 2007
New Revision: 39863
URL: http://svn.opensuse.org/viewcvs/yast?rev=39863&view=rev
Log:
add preferredWidth()/Height()
Modified:
branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc
branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h
Modified: branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc
URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc?rev=39863&r1=39862&r2=39863&view=diff
==============================================================================
--- branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc (original)
+++ branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc Wed Aug 1 12:06:30 2007
@@ -70,7 +70,8 @@
sellist->SetSepWidht( 0 );
sellist->SetHotCol( 0 );
- addChild( sellist );
+ // don' t call addChild any longer!
+ //addChild( sellist );
}
///////////////////////////////////////////////////////////////////
@@ -85,7 +86,7 @@
{
if ( !sellist )
return;
-
+ NCMIL << "Calling NCPopupTable::addItem" << endl;
sellist->addItem( id, row );
}
@@ -158,3 +159,21 @@
sellist->stripHotkeys();
}
}
+
+int NCPopupTable::preferredWidth()
+{
+ wsze sze = wGetDefsze();
+ if ( sellist )
+ return sellist->preferredWidth();
+ else
+ return sze.W;
+}
+
+int NCPopupTable::preferredHeight()
+{
+ wsze sze = wGetDefsze();
+ if ( sellist )
+ return sellist->preferredHeight();
+ else
+ return sze.H;
+}
Modified: branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h
URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h?rev=39863&r1=39862&r2=39863&view=diff
==============================================================================
--- branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h (original)
+++ branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h Wed Aug 1 12:06:30 2007
@@ -65,6 +65,10 @@
public:
void stripHotkeys();
+
+ int preferredWidth();
+ int preferredHeight();
+
};
///////////////////////////////////////////////////////////////////
--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx
Date: Wed Aug 1 12:06:30 2007
New Revision: 39863
URL: http://svn.opensuse.org/viewcvs/yast?rev=39863&view=rev
Log:
add preferredWidth()/Height()
Modified:
branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc
branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h
Modified: branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc
URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc?rev=39863&r1=39862&r2=39863&view=diff
==============================================================================
--- branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc (original)
+++ branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.cc Wed Aug 1 12:06:30 2007
@@ -70,7 +70,8 @@
sellist->SetSepWidht( 0 );
sellist->SetHotCol( 0 );
- addChild( sellist );
+ // don' t call addChild any longer!
+ //addChild( sellist );
}
///////////////////////////////////////////////////////////////////
@@ -85,7 +86,7 @@
{
if ( !sellist )
return;
-
+ NCMIL << "Calling NCPopupTable::addItem" << endl;
sellist->addItem( id, row );
}
@@ -158,3 +159,21 @@
sellist->stripHotkeys();
}
}
+
+int NCPopupTable::preferredWidth()
+{
+ wsze sze = wGetDefsze();
+ if ( sellist )
+ return sellist->preferredWidth();
+ else
+ return sze.W;
+}
+
+int NCPopupTable::preferredHeight()
+{
+ wsze sze = wGetDefsze();
+ if ( sellist )
+ return sellist->preferredHeight();
+ else
+ return sze.H;
+}
Modified: branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h
URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h?rev=39863&r1=39862&r2=39863&view=diff
==============================================================================
--- branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h (original)
+++ branches/tmp/sh/mod-ui/ncurses/src/NCPopupTable.h Wed Aug 1 12:06:30 2007
@@ -65,6 +65,10 @@
public:
void stripHotkeys();
+
+ int preferredWidth();
+ int preferredHeight();
+
};
///////////////////////////////////////////////////////////////////
--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx
| < Previous | Next > |