Initialize previously uninitialized members.
This commit is contained in:
@@ -41,7 +41,7 @@ namespace glabels
|
||||
|
||||
|
||||
ColorButton::ColorButton( QWidget* parent )
|
||||
: QPushButton( parent )
|
||||
: QPushButton( parent ), mIsDefault(0), mDialog(nullptr)
|
||||
{
|
||||
// empty
|
||||
}
|
||||
|
||||
+13
-2
@@ -84,14 +84,25 @@ namespace glabels
|
||||
LabelEditor::LabelEditor( QScrollArea* scrollArea, QWidget* parent )
|
||||
: QWidget(parent), mScrollArea(scrollArea)
|
||||
{
|
||||
mState = IdleState;
|
||||
|
||||
mModel = nullptr;
|
||||
mUndoRedoModel = nullptr;
|
||||
|
||||
mZoom = 1;
|
||||
mZoomToFitFlag = false;
|
||||
mScale = 1;
|
||||
mMarkupVisible = true;
|
||||
mGridVisible = true;
|
||||
mGridSpacing = 18;
|
||||
|
||||
mState = IdleState;
|
||||
|
||||
mSelectRegionVisible = false;
|
||||
mResizeObject = nullptr;
|
||||
mResizeHandle = nullptr;
|
||||
mResizeHonorAspect = false;
|
||||
mCreateObjectType = Box;
|
||||
mCreateObject = nullptr;
|
||||
|
||||
setMouseTracking( true );
|
||||
setFocusPolicy(Qt::StrongFocus);
|
||||
|
||||
|
||||
@@ -176,6 +176,9 @@ namespace glabels
|
||||
|
||||
QScrollArea* mScrollArea;
|
||||
|
||||
model::Model* mModel;
|
||||
UndoRedoModel* mUndoRedoModel;
|
||||
|
||||
double mZoom;
|
||||
bool mZoomToFitFlag;
|
||||
double mScale;
|
||||
@@ -188,9 +191,6 @@ namespace glabels
|
||||
double mGridSpacing;
|
||||
model::Distance mStepSize;
|
||||
|
||||
model::Model* mModel;
|
||||
UndoRedoModel* mUndoRedoModel;
|
||||
|
||||
State mState;
|
||||
|
||||
/* ArrowSelectRegion state */
|
||||
|
||||
@@ -34,7 +34,7 @@ namespace glabels
|
||||
/// Constructor
|
||||
///
|
||||
MergeView::MergeView( QWidget *parent )
|
||||
: QWidget(parent), mModel(nullptr), mBlock(false)
|
||||
: QWidget(parent), mModel(nullptr), mUndoRedoModel(nullptr), mBlock(false), mOldFormatComboIndex(0)
|
||||
{
|
||||
setupUi( this );
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ namespace glabels
|
||||
/// Constructor
|
||||
///
|
||||
PropertiesView::PropertiesView( QWidget *parent )
|
||||
: QWidget(parent), mModel(nullptr)
|
||||
: QWidget(parent), mModel(nullptr), mUndoRedoModel(nullptr)
|
||||
{
|
||||
setupUi( this );
|
||||
|
||||
|
||||
+2
-20
@@ -54,7 +54,8 @@ namespace glabels
|
||||
///
|
||||
/// Default constructor.
|
||||
///
|
||||
Model::Model() : mUntitledInstance(0), mModified(true), mTmplate(nullptr), mRotate(false)
|
||||
Model::Model()
|
||||
: mUntitledInstance(0), mModified(true), mTmplate(nullptr), mFrame(nullptr), mRotate(false)
|
||||
{
|
||||
mMerge = new merge::None();
|
||||
}
|
||||
@@ -88,7 +89,6 @@ namespace glabels
|
||||
mUntitledInstance = savedModel->mUntitledInstance;
|
||||
mModified = savedModel->mModified;
|
||||
mFileName = savedModel->mFileName;
|
||||
mCompressionLevel = savedModel->mCompressionLevel;
|
||||
mTmplate = savedModel->mTmplate;
|
||||
mFrame = savedModel->mFrame;
|
||||
mRotate = savedModel->mRotate;
|
||||
@@ -150,24 +150,6 @@ namespace glabels
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Get compression level
|
||||
///
|
||||
int Model::compressionLevel() const
|
||||
{
|
||||
return mCompressionLevel;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Set compression level
|
||||
///
|
||||
void Model::setCompressionLevel( int compressionLevel )
|
||||
{
|
||||
mCompressionLevel = compressionLevel;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Get template
|
||||
///
|
||||
|
||||
@@ -93,9 +93,6 @@ namespace glabels
|
||||
const QString& fileName() const;
|
||||
void setFileName( const QString &fileName );
|
||||
|
||||
int compressionLevel() const;
|
||||
void setCompressionLevel( int compressionLevel );
|
||||
|
||||
const Template* tmplate() const;
|
||||
const Frame* frame() const;
|
||||
void setTmplate( const Template* tmplate );
|
||||
@@ -225,7 +222,6 @@ namespace glabels
|
||||
int mUntitledInstance;
|
||||
bool mModified;
|
||||
QString mFileName;
|
||||
int mCompressionLevel;
|
||||
const Template* mTmplate;
|
||||
const Frame* mFrame;
|
||||
bool mRotate;
|
||||
|
||||
@@ -111,6 +111,7 @@ namespace glabels
|
||||
mBcStyle = bcStyle;
|
||||
mBcTextFlag = bcTextFlag;
|
||||
mBcChecksumFlag = bcChecksumFlag;
|
||||
mBcFormatDigits = mBcStyle.preferedN();
|
||||
mBcData = bcData;
|
||||
mBcColorNode = bcColorNode;
|
||||
|
||||
|
||||
@@ -47,9 +47,9 @@ namespace glabels
|
||||
|
||||
|
||||
PageRenderer::PageRenderer( const Model* model )
|
||||
: mModel(nullptr), mNCopies(0), mStartLabel(0),
|
||||
: mModel(nullptr), mMerge(nullptr), mNCopies(0), mStartLabel(0), mLastLabel(0),
|
||||
mPrintOutlines(false), mPrintCropMarks(false), mPrintReverse(false),
|
||||
mIPage(0), mIsMerge(false), mNPages(0)
|
||||
mIPage(0), mIsMerge(false), mNPages(0), mNLabelsPerPage(0)
|
||||
{
|
||||
if ( model )
|
||||
{
|
||||
|
||||
@@ -878,16 +878,16 @@
|
||||
<context>
|
||||
<name>glabels::LabelEditor</name>
|
||||
<message>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="641"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="941"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="946"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="951"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="956"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="652"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="952"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="957"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="962"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="967"/>
|
||||
<source>Move</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="961"/>
|
||||
<location filename="../glabels/LabelEditor.cpp" line="972"/>
|
||||
<source>Delete</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
||||
Reference in New Issue
Block a user