Author: rpmcruz
Date: Thu Jul 17 11:34:02 2008
New Revision: 49205
URL: http://svn.opensuse.org/viewcvs/yast?rev=49205&view=rev
Log:
* src/YGWidget.cc: got rid of the size calculation cache. Should fix
some issues when using replace points.
* src/YGPackageSelector.cc: let the wrapper do an initial check on
changes. Should fix bug 400635.
Modified:
trunk/gtk/ChangeLog
trunk/gtk/src/YGDialog.cc
trunk/gtk/src/YGPackageSelector.cc
trunk/gtk/src/YGWidget.cc
trunk/gtk/src/YGWidget.h
Modified: trunk/gtk/ChangeLog
URL: http://svn.opensuse.org/viewcvs/yast/trunk/gtk/ChangeLog?rev=49205&r1=49204&r2=49205&view=diff
==============================================================================
--- trunk/gtk/ChangeLog (original)
+++ trunk/gtk/ChangeLog Thu Jul 17 11:34:02 2008
@@ -1,3 +1,11 @@
+2008-07-17 Ricardo Cruz
+
+ * src/YGWidget.cc: got rid of the size calculation cache. Should fix
+ some issues when using replace points.
+
+ * src/YGPackageSelector.cc: let the wrapper do an initial check on
+ changes. Should fix bug 400635.
+
2008-07-16 Ricardo Cruz
* src/YGTable.cc: implemented YTable's multiSelection flag.
Modified: trunk/gtk/src/YGDialog.cc
URL: http://svn.opensuse.org/viewcvs/yast/trunk/gtk/src/YGDialog.cc?rev=49205&r1=49204&r2=49205&view=diff
==============================================================================
--- trunk/gtk/src/YGDialog.cc (original)
+++ trunk/gtk/src/YGDialog.cc Thu Jul 17 11:34:02 2008
@@ -393,7 +393,6 @@
void YGDialog::setSize (int width, int height)
{
-//fprintf (stderr, "dialog: set size: %d x %d\n", width, height);
// libyui calls YDialog::setSize() to force a geometry recalculation as a
// result of changed layout properties
GtkWidget *window = m_window->getWidget();
Modified: trunk/gtk/src/YGPackageSelector.cc
URL: http://svn.opensuse.org/viewcvs/yast/trunk/gtk/src/YGPackageSelector.cc?rev=49205&r1=49204&r2=49205&view=diff
==============================================================================
--- trunk/gtk/src/YGPackageSelector.cc (original)
+++ trunk/gtk/src/YGPackageSelector.cc Thu Jul 17 11:34:02 2008
@@ -829,12 +829,9 @@
Ypp::QueryPool::Query *query = new Ypp::QueryPool::Query();
query->setIsModified (true);
- if (update_mode) {
+ if (update_mode)
query->addType (Ypp::Package::PATCH_TYPE);
- m_pool = new Ypp::QueryPool (query);
- }
- else
- m_pool = new Ypp::QueryPool (query, !summary_mode);
+ m_pool = new Ypp::QueryPool (query);
// initialize list -- there could already be packages modified
for (Ypp::Pool::Iter it = m_pool->getFirst(); it; it = m_pool->getNext (it))
ChangesPane::entryInserted (it, m_pool->get (it));
Modified: trunk/gtk/src/YGWidget.cc
URL: http://svn.opensuse.org/viewcvs/yast/trunk/gtk/src/YGWidget.cc?rev=49205&r1=49204&r2=49205&view=diff
==============================================================================
--- trunk/gtk/src/YGWidget.cc (original)
+++ trunk/gtk/src/YGWidget.cc Thu Jul 17 11:34:02 2008
@@ -48,7 +48,6 @@
ywidget->setParent (yparent);
yparent->addChild (ywidget);
}
- m_sizeReq.width = 0;
}
YGWidget::~YGWidget()
@@ -114,9 +113,10 @@
int YGWidget::getPreferredSize (YUIDimension dimension)
{
- if (!m_sizeReq.width)
- gtk_widget_size_request (m_adj_size, &m_sizeReq);
- return dimension == YD_HORIZ ? m_sizeReq.width : m_sizeReq.height;
+ // We might want to try to do some caching here..
+ GtkRequisition req;
+ gtk_widget_size_request (m_adj_size, &req);
+ return dimension == YD_HORIZ ? req.width : req.height;
}
#include "ygtkfixed.h"
@@ -129,7 +129,6 @@
if (parent && YGTK_IS_FIXED (parent))
ygtk_fixed_set_child_size (YGTK_FIXED (parent), m_adj_size, width, height);
- m_sizeReq.width = 0;
}
void YGWidget::emitEvent(YEvent::EventReason reason, bool if_notify,
Modified: trunk/gtk/src/YGWidget.h
URL: http://svn.opensuse.org/viewcvs/yast/trunk/gtk/src/YGWidget.h?rev=49205&r1=49204&r2=49205&view=diff
==============================================================================
--- trunk/gtk/src/YGWidget.h (original)
+++ trunk/gtk/src/YGWidget.h Thu Jul 17 11:34:02 2008
@@ -51,7 +51,6 @@
// layout
virtual int getPreferredSize (YUIDimension dimension);
void doSetSize (int width, int height);
- GtkRequisition m_sizeReq; // cache
void show();
--
To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org
For additional commands, e-mail: yast-commit+help@opensuse.org