Skip to content

Commit 1f53221

Browse files
committedAug 24, 2012
fix warnings
1 parent 0cd6177 commit 1f53221

File tree

2 files changed

+36
-34
lines changed

2 files changed

+36
-34
lines changed
 

‎src/core/raster/qgsrastertransparency.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ int QgsRasterTransparency::alphaValue( double theValue, int theGlobalTransparenc
110110

111111
//Search through the transparency list looking for a match
112112
bool myTransparentPixelFound = false;
113-
TransparentSingleValuePixel myTransparentPixel = {0, 100};
113+
TransparentSingleValuePixel myTransparentPixel = {0, 0, 100};
114114
for ( int myListRunner = 0; myListRunner < mTransparentSingleValuePixelList.count(); myListRunner++ )
115115
{
116116
myTransparentPixel = mTransparentSingleValuePixelList[myListRunner];

‎src/gui/qgsrasterlayersaveasdialog.cpp

Lines changed: 35 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -17,59 +17,59 @@
1717
// #include <QStylePainter>
1818

1919
GroupBox::GroupBox( QWidget *parent )
20-
: QGroupBox( parent ), m_collapsed( false )
20+
: QGroupBox( parent ), m_collapsed( false )
2121
{
22-
connect( this, SIGNAL( toggled ( bool ) ), this, SLOT( setToggled( bool ) ) );
22+
connect( this, SIGNAL( toggled( bool ) ), this, SLOT( setToggled( bool ) ) );
2323
//setToggled( isChecked() );
2424
}
2525

2626
GroupBox::GroupBox( const QString &title, QWidget *parent )
27-
: QGroupBox(title, parent ), m_collapsed( false )
27+
: QGroupBox( title, parent ), m_collapsed( false )
2828
{}
2929

3030
bool GroupBox::isCollapsed() { return m_collapsed; }
3131

3232
// void GroupBox::mousePressEvent( QMouseEvent *e )
3333
// {
3434
// QgsDebugMsg("press event");
35-
// if( e->button() == Qt::LeftButton )
36-
// {
35+
// if( e->button() == Qt::LeftButton )
36+
// {
3737
// QgsDebugMsg("left but");
38-
// QStyleOptionGroupBox option;
39-
// initStyleOption( &option );
40-
// QRect buttonArea( 0, 0, 16, 16 );
41-
// buttonArea.moveTopRight( option.rect.adjusted( 0, 0, -10, 0
38+
// QStyleOptionGroupBox option;
39+
// initStyleOption( &option );
40+
// QRect buttonArea( 0, 0, 16, 16 );
41+
// buttonArea.moveTopRight( option.rect.adjusted( 0, 0, -10, 0
4242
// ).topRight() );
43-
// if( buttonArea.contains( e->pos() ) )
44-
// {
45-
// clickPos = e->pos();
46-
// return;
47-
// }
48-
// }
49-
// QGroupBox::mousePressEvent( e );
43+
// if( buttonArea.contains( e->pos() ) )
44+
// {
45+
// clickPos = e->pos();
46+
// return;
47+
// }
48+
// }
49+
// QGroupBox::mousePressEvent( e );
5050
// }
5151

5252
// void GroupBox::mouseReleaseEvent( QMouseEvent *e )
5353
// {
5454
// QgsDebugMsg("release");
55-
// if( e->button() == Qt::LeftButton && clickPos == e->pos() )
56-
// setCollapse( !isCollapsed() );
55+
// if( e->button() == Qt::LeftButton && clickPos == e->pos() )
56+
// setCollapse( !isCollapsed() );
5757
// }
5858

5959
// void GroupBox::paintEvent( QPaintEvent * )
6060
// {
6161
// QgsDebugMsg("paint event");
6262

6363
// QStylePainter paint( this );
64-
// QStyleOptionGroupBox option;
65-
// initStyleOption( &option );
66-
// paint.drawComplexControl( QStyle::CC_GroupBox, option );
67-
// paint.drawItemPixmap(
68-
// option.rect.adjusted( 0, 0, -10, 0 ),
69-
// Qt::AlignTop | Qt::AlignRight,
70-
// QPixmap( m_collapsed ?
71-
// ":/images/images/navigate_down2_16x16.png" :
72-
// ":/images/images/navigate_up2_16x16.png" ) );
64+
// QStyleOptionGroupBox option;
65+
// initStyleOption( &option );
66+
// paint.drawComplexControl( QStyle::CC_GroupBox, option );
67+
// paint.drawItemPixmap(
68+
// option.rect.adjusted( 0, 0, -10, 0 ),
69+
// Qt::AlignTop | Qt::AlignRight,
70+
// QPixmap( m_collapsed ?
71+
// ":/images/images/navigate_down2_16x16.png" :
72+
// ":/images/images/navigate_up2_16x16.png" ) );
7373
// }
7474

7575
void GroupBox::showEvent( QShowEvent * event )
@@ -86,13 +86,13 @@ void GroupBox::setCollapsed( bool collapse )
8686
return;
8787
// QgsDebugMsg(QString("%1 setcollapse %2").arg(objectName()).arg(collapse));
8888

89-
// minimize layout margins, restore later
89+
// minimize layout margins, restore later
9090
if ( collapse )
9191
{
9292
if ( layout() )
93-
{
93+
{
9494
margins = layout()->contentsMargins();
95-
layout()->setContentsMargins(1,1,1,1);
95+
layout()->setContentsMargins( 1, 1, 1, 1 );
9696
}
9797
}
9898
else
@@ -103,9 +103,9 @@ void GroupBox::setCollapsed( bool collapse )
103103
}
104104
}
105105
m_collapsed = collapse;
106-
foreach( QWidget *widget, findChildren<QWidget*>() )
106+
foreach ( QWidget *widget, findChildren<QWidget*>() )
107107
widget->setHidden( collapse );
108-
108+
109109
if ( m_collapsed )
110110
emit collapsed( this );
111111
else
@@ -193,7 +193,7 @@ QgsRasterLayerSaveAsDialog::QgsRasterLayerSaveAsDialog( QgsRasterLayer* rasterLa
193193

194194
// this should scroll down to make widget visible, but it's not happening
195195
// (at least part of it is visible)...
196-
connect( mCreateOptionsGroupBox, SIGNAL( expanded( QWidget* ) ),
196+
connect( mCreateOptionsGroupBox, SIGNAL( expanded( QWidget* ) ),
197197
this, SLOT( groupBoxExpanded( QWidget* ) ) );
198198

199199
}
@@ -690,6 +690,8 @@ void QgsRasterLayerSaveAsDialog::addNoDataRow( double min, double max )
690690

691691
void QgsRasterLayerSaveAsDialog::noDataCellTextEdited( const QString & text )
692692
{
693+
Q_UNUSED( text );
694+
693695
QLineEdit *lineEdit = dynamic_cast<QLineEdit *>( sender() );
694696
if ( !lineEdit ) return;
695697
int row = -1;

0 commit comments

Comments
 (0)
Please sign in to comment.