summaryrefslogtreecommitdiff
authorzecke <zecke>2002-10-06 11:24:13 (UTC)
committer zecke <zecke>2002-10-06 11:24:13 (UTC)
commita8a476782082bd340690308673983bc7e3238db5 (patch) (unidiff)
treee1bf10867cea30701bc800a90ca03e0b99c0dc60
parent4209ade719759f4b079bdd40baa4d255ce1e9d3a (diff)
downloadopie-a8a476782082bd340690308673983bc7e3238db5.zip
opie-a8a476782082bd340690308673983bc7e3238db5.tar.gz
opie-a8a476782082bd340690308673983bc7e3238db5.tar.bz2
Man man,
NO default parameters in the implementation please! patch by ibotty
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--libopie/otabbar.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libopie/otabbar.cpp b/libopie/otabbar.cpp
index b5b93ba..52621ca 100644
--- a/libopie/otabbar.cpp
+++ b/libopie/otabbar.cpp
@@ -10,49 +10,49 @@
10:`=1 )Y*s>-.--   : the terms of the GNU Library General Public 10:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
11.="- .-=="i,     .._ License as published by the Free Software 11.="- .-=="i,     .._ License as published by the Free Software
12 - .   .-<_>     .<> Foundation; either version 2 of the License, 12 - .   .-<_>     .<> Foundation; either version 2 of the License,
13     ._= =}       : or (at your option) any later version. 13     ._= =}       : or (at your option) any later version.
14    .%`+i>       _;_. 14    .%`+i>       _;_.
15    .i_,=:_.      -<s. This program is distributed in the hope that 15    .i_,=:_.      -<s. This program is distributed in the hope that
16     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY; 16     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
17    : ..    .:,     . . . without even the implied warranty of 17    : ..    .:,     . . . without even the implied warranty of
18    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A 18    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
19  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU 19  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
20..}^=.=       =       ; Library General Public License for more 20..}^=.=       =       ; Library General Public License for more
21++=   -.     .`     .: details. 21++=   -.     .`     .: details.
22 :     =  ...= . :.=- 22 :     =  ...= . :.=-
23 -.   .:....=;==+<; You should have received a copy of the GNU 23 -.   .:....=;==+<; You should have received a copy of the GNU
24  -_. . .   )=.  = Library General Public License along with 24  -_. . .   )=.  = Library General Public License along with
25    --        :-=` this library; see the file COPYING.LIB. 25    --        :-=` this library; see the file COPYING.LIB.
26 If not, write to the Free Software Foundation, 26 If not, write to the Free Software Foundation,
27 Inc., 59 Temple Place - Suite 330, 27 Inc., 59 Temple Place - Suite 330,
28 Boston, MA 02111-1307, USA. 28 Boston, MA 02111-1307, USA.
29 29
30*/ 30*/
31 31
32#include "otabbar.h" 32#include "otabbar.h"
33 33
34OTabBar::OTabBar( QWidget *parent = 0, const char *name = 0 ) 34OTabBar::OTabBar( QWidget *parent , const char *name )
35 : QTabBar( parent, name ) 35 : QTabBar( parent, name )
36{ 36{
37} 37}
38 38
39void OTabBar::paintLabel( QPainter* p, const QRect& br, QTab* t, bool has_focus ) const 39void OTabBar::paintLabel( QPainter* p, const QRect& br, QTab* t, bool has_focus ) const
40{ 40{
41 41
42 QRect r = br; 42 QRect r = br;
43 if ( t->iconset) 43 if ( t->iconset)
44 { 44 {
45 QIconSet::Mode mode = (t->enabled && isEnabled()) ? QIconSet::Normal : QIconSet::Disabled; 45 QIconSet::Mode mode = (t->enabled && isEnabled()) ? QIconSet::Normal : QIconSet::Disabled;
46 if ( mode == QIconSet::Normal && has_focus ) { 46 if ( mode == QIconSet::Normal && has_focus ) {
47 mode = QIconSet::Active; 47 mode = QIconSet::Active;
48 } 48 }
49 QPixmap pixmap = t->iconset->pixmap( QIconSet::Small, mode ); 49 QPixmap pixmap = t->iconset->pixmap( QIconSet::Small, mode );
50 int pixw = pixmap.width(); 50 int pixw = pixmap.width();
51 int pixh = pixmap.height(); 51 int pixh = pixmap.height();
52 r.setLeft( r.left() + pixw + 2 ); 52 r.setLeft( r.left() + pixw + 2 );
53 p->drawPixmap( br.left()+2, br.center().y()-pixh/2, pixmap ); 53 p->drawPixmap( br.left()+2, br.center().y()-pixh/2, pixmap );
54 } 54 }
55 55
56 QRect tr = r; 56 QRect tr = r;
57 if ( t->id == currentTab() ) 57 if ( t->id == currentTab() )
58 { 58 {