Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move georeferencer sources from plugins to app
- Loading branch information
1 parent
788180c
commit 80a29fd
Showing
93 changed files
with
154 additions
and
198 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
/*************************************************************************** | ||
qgsvalidateddoublespinbox.cpp | ||
-------------------------------------- | ||
Date : 23-Feb-2010 | ||
Copyright : (c) 2010 by Manuel Massing | ||
Email : m.massing at warped-space.de | ||
*************************************************************************** | ||
* * | ||
* This program is free software; you can redistribute it and/or modify * | ||
* it under the terms of the GNU General Public License as published by * | ||
* the Free Software Foundation; either version 2 of the License, or * | ||
* (at your option) any later version. * | ||
* * | ||
***************************************************************************/ | ||
|
||
#include "qgsvalidateddoublespinbox.h" | ||
|
||
QgsValidatedDoubleSpinBox::QgsValidatedDoubleSpinBox( QWidget *widget ) | ||
: QDoubleSpinBox( widget ) | ||
{ } | ||
|
||
QValidator::State QgsValidatedDoubleSpinBox::validate( QString &input, int &pos ) const | ||
{ | ||
QValidator::State state = QDoubleSpinBox::validate( input, pos ); | ||
if ( state != QValidator::Acceptable ) | ||
{ | ||
return state; | ||
} | ||
|
||
// A value of zero is acceptable as intermediate result, | ||
// but not as final entry | ||
double val = valueFromText( input ); | ||
if ( val == 0.0 ) | ||
{ | ||
return QValidator::Intermediate; | ||
} | ||
return QValidator::Acceptable; | ||
} | ||
|
||
QAbstractSpinBox::StepEnabled QgsValidatedDoubleSpinBox::stepEnabled() const | ||
{ | ||
StepEnabled mayStep = StepNone; | ||
|
||
// Zero is off limits, so handle the logic differently | ||
// (always exclude zero from the permitted interval) | ||
if ( minimum() == 0.0 ) | ||
{ | ||
if ( value() - singleStep() > minimum() ) | ||
{ | ||
mayStep |= StepDownEnabled; | ||
} | ||
} | ||
else // closed interval | ||
{ | ||
if ( value() - singleStep() >= minimum() ) | ||
{ | ||
mayStep |= StepDownEnabled; | ||
} | ||
} | ||
|
||
if ( maximum() == 0.0 ) | ||
{ | ||
if ( value() + singleStep() < maximum() ) | ||
{ | ||
mayStep |= StepUpEnabled; | ||
} | ||
} | ||
else | ||
{ | ||
if ( value() + singleStep() <= maximum() ) | ||
{ | ||
mayStep |= StepUpEnabled; | ||
} | ||
} | ||
return mayStep; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/*************************************************************************** | ||
qgsvalidateddoublespinbox.h - Simple extension to QDoubleSpinBox which | ||
implements a validate function to disallow zero as input. | ||
-------------------------------------- | ||
Date : 23-Feb-2010 | ||
Copyright : (c) 2010 by Manuel Massing | ||
Email : m.massing at warped-space.de | ||
*************************************************************************** | ||
* * | ||
* This program is free software; you can redistribute it and/or modify * | ||
* it under the terms of the GNU General Public License as published by * | ||
* the Free Software Foundation; either version 2 of the License, or * | ||
* (at your option) any later version. * | ||
* * | ||
***************************************************************************/ | ||
|
||
#ifndef QGSVALIDATEDDOUBLESPINBOX_H | ||
#define QGSVALIDATEDDOUBLESPINBOX_H | ||
|
||
#include <QDoubleSpinBox> | ||
|
||
class QgsValidatedDoubleSpinBox : public QDoubleSpinBox | ||
{ | ||
Q_OBJECT | ||
|
||
public: | ||
QgsValidatedDoubleSpinBox( QWidget *widget ); | ||
|
||
QValidator::State validate( QString &input, int &pos ) const override; | ||
StepEnabled stepEnabled() const override; | ||
}; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.