summaryrefslogtreecommitdiff
path: root/libopie2/opieui/big-screen
authorar <ar>2004-06-02 22:20:53 (UTC)
committer ar <ar>2004-06-02 22:20:53 (UTC)
commit9135254f2b593741cf7b0ffd80bb8bb63986333d (patch) (side-by-side diff)
tree98248548d823b97970b2240695c958b7ce440a9d /libopie2/opieui/big-screen
parent8fe425e226eefcd652c4cb875d68fbd886d4c42c (diff)
downloadopie-9135254f2b593741cf7b0ffd80bb8bb63986333d.zip
opie-9135254f2b593741cf7b0ffd80bb8bb63986333d.tar.gz
opie-9135254f2b593741cf7b0ffd80bb8bb63986333d.tar.bz2
- convert to odebug framework
Diffstat (limited to 'libopie2/opieui/big-screen') (more/less context) (show whitespace changes)
-rw-r--r--libopie2/opieui/big-screen/osplitter.cpp25
-rw-r--r--libopie2/opieui/big-screen/owidgetstack.cpp5
2 files changed, 17 insertions, 13 deletions
diff --git a/libopie2/opieui/big-screen/osplitter.cpp b/libopie2/opieui/big-screen/osplitter.cpp
index f0287ed..f50e7f0 100644
--- a/libopie2/opieui/big-screen/osplitter.cpp
+++ b/libopie2/opieui/big-screen/osplitter.cpp
@@ -27,12 +27,13 @@
*/
#include "osplitter.h"
/* OPIE */
#include <opie2/otabwidget.h>
+#include <opie2/odebug.h>
/* QT */
#include <qvaluelist.h>
#include <qvbox.h>
using namespace Opie::Ui;
@@ -78,13 +79,13 @@ OSplitter::OSplitter( Orientation orient, QWidget* parent, const char* name, WFl
* Destructor destructs this object and cleans up. All child
* widgets will be deleted
* @see addWidget
*/
OSplitter::~OSplitter()
{
- qWarning("Deleted Splitter");
+ owarn << "Deleted Splitter" << oendl;
m_splitter.setAutoDelete( true );
m_splitter.clear();
delete m_hbox;
delete m_tabWidget;
}
@@ -207,13 +208,13 @@ void OSplitter::removeWidget( OSplitter* split)
*/
void OSplitter::addWidget( QWidget* wid, const QString& icon, const QString& label )
{
#ifdef DEBUG
if (!wid )
{
- qWarning("Widget is not valid!");
+ owarn << "Widget is not valid!" << oendl;
return;
}
#endif
OSplitterContainer cont;
cont.widget = wid;
cont.icon =icon;
@@ -363,15 +364,15 @@ QSize OSplitter::minimumSizeHint()const
void OSplitter::resizeEvent( QResizeEvent* res )
{
QFrame::resizeEvent( res );
/*
*
*/
- // qWarning("Old size was width = %d height = %d", res->oldSize().width(), res->oldSize().height() );
+ // owarn << "Old size was width = " << res->oldSize().width() << " height = " << res->oldSize().height() << "" << oendl;
bool mode = true;
- qWarning("New size is width = %d height = %d %s", res->size().width(), res->size().height(), name() );
+ owarn << "New size is width = " << res->size().width() << " height = " << res->size().height() << " " << name() << "" << oendl;
if ( res->size().width() > m_size_policy &&
m_orient == Horizontal )
{
changeHBox();
mode = false;
}
@@ -382,13 +383,13 @@ void OSplitter::resizeEvent( QResizeEvent* res )
{
changeTab();
}
else if ( res->size().height() > m_size_policy &&
m_orient == Vertical )
{
- qWarning("Changng to vbox %s", name() );
+ owarn << "Changng to vbox " << name() << "" << oendl;
changeVBox();
mode = false;
}
emit sizeChanged(mode, m_orient );
}
@@ -441,13 +442,13 @@ void OSplitter::changeTab()
raise();
show();
m_tabWidget->setGeometry( frameRect() );
return;
}
- qWarning(" New Tab Widget %s", name() );
+ owarn << " New Tab Widget " << name() << "" << oendl;
/*
* and add all widgets this will reparent them
* delete m_hbox set it to 0
*
*/
OTabWidget *tab;
@@ -468,13 +469,13 @@ void OSplitter::changeTab()
connect(tab, SIGNAL(currentChanged(QWidget*) ),
this, SIGNAL(currentChanged(QWidget*) ) );
for ( ContainerList::Iterator it = m_container.begin(); it != m_container.end(); ++it )
{
- qWarning("Widget is %s", (*it).name.latin1() );
+ owarn << "Widget is " << (*it).name << "" << oendl;
addToTab( (*it) );
}
for ( OSplitter* split = m_splitter.first(); split; split = m_splitter.next() )
{
split->reparent(this, 0, QPoint(0, 0) );
@@ -501,26 +502,26 @@ void OSplitter::changeHBox()
if (m_hbox )
{
m_hbox->setGeometry( frameRect() );
return;
}
- qWarning("new HBox %s", name() );
+ owarn << "new HBox " << name() << "" << oendl;
m_hbox = new QHBox( this );
commonChangeBox();
}
void OSplitter::changeVBox()
{
if (m_hbox )
{
m_hbox->setGeometry( frameRect() );
return;
}
- qWarning("New VBOX %s", name() );
+ owarn << "New VBOX " << name() << "" << oendl;
m_hbox = new QVBox( this );
commonChangeBox();
}
@@ -529,20 +530,20 @@ void OSplitter::changeVBox()
* first remove and add children
* the other splitters
* it is recursive as well due the call to setTabWidget
*/
void OSplitter::commonChangeBox()
{
- qWarning(" Name of Splitters is %s", name() );
+ owarn << " Name of Splitters is " << name() << "" << oendl;
for (ContainerList::Iterator it = m_container.begin(); it != m_container.end(); ++it )
{
/* only if parent tab.. m_tabWidgets gets deleted and would do that as well */
if (m_parentTab )
removeFromTab( (*it).widget );
- qWarning("Adding to box %s", (*it).name.latin1() );
+ owarn << "Adding to box " << (*it).name << "" << oendl;
addToBox( (*it) );
}
for ( OSplitter* split = m_splitter.first(); split; split = m_splitter.next() )
{
/* tell them the world had changed */
split->setTabWidget( 0 );
@@ -556,13 +557,13 @@ void OSplitter::commonChangeBox()
if (m_parentTab )
m_parentTab->addTab(m_hbox, iconName(), label() );
else
{
- qWarning(" setting Box geometry for %s", name() );
+ owarn << " setting Box geometry for " << name() << "" << oendl;
m_hbox->setGeometry( frameRect() );
m_hbox->show();
delete m_tabWidget;
m_tabWidget = 0;
show(); // also show this widget
}
diff --git a/libopie2/opieui/big-screen/owidgetstack.cpp b/libopie2/opieui/big-screen/owidgetstack.cpp
index a0a6355..de7f83f 100644
--- a/libopie2/opieui/big-screen/owidgetstack.cpp
+++ b/libopie2/opieui/big-screen/owidgetstack.cpp
@@ -25,12 +25,15 @@
Boston, MA 02111-1307, USA.
*/
#include "owidgetstack.h"
+/* OPIE */
+#include <opie2/odebug.h>
+
/* QT */
#include <qapplication.h>
#include <qwidgetstack.h>
namespace Opie {
namespace Ui {
@@ -304,13 +307,13 @@ void OWidgetStack::hideWidget( QWidget* wid) {
raiseWidget( wid );
}
bool OWidgetStack::eventFilter( QObject* obj, QEvent* e) {
- qWarning(" %s %s", obj->name(), obj->className() );
+ owarn << " " << obj->name() << " " << obj->className() << "" << oendl;
if ( e->type() == QEvent::Resize ) {
QResizeEvent *res = static_cast<QResizeEvent*>( e );
QSize size = res->size();
if ( size.width() >= mode_size )
switchTop();
else