page layout editor: fix a crash on block move.
This crash was due to a pointer initialized to a temporary reference. Very minor coding style fixes
This commit is contained in:
parent
83d5a770e8
commit
2230abde1b
|
@ -177,6 +177,7 @@ wxString WS_DRAW_ITEM_LIST::BuildFullText( const wxString& aTextbase )
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'Z':
|
case 'Z':
|
||||||
|
if( m_paperFormat )
|
||||||
msg += *m_paperFormat;
|
msg += *m_paperFormat;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -196,11 +197,12 @@ wxString WS_DRAW_ITEM_LIST::BuildFullText( const wxString& aTextbase )
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'L':
|
case 'L':
|
||||||
|
if( m_sheetLayer )
|
||||||
msg += *m_sheetLayer;
|
msg += *m_sheetLayer;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'P':
|
case 'P':
|
||||||
msg += *m_sheetFullName;
|
msg += m_sheetFullName;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'Y':
|
case 'Y':
|
||||||
|
|
|
@ -388,7 +388,7 @@ protected:
|
||||||
const TITLE_BLOCK* m_titleBlock; // for basic inscriptions
|
const TITLE_BLOCK* m_titleBlock; // for basic inscriptions
|
||||||
const wxString* m_paperFormat; // for basic inscriptions
|
const wxString* m_paperFormat; // for basic inscriptions
|
||||||
wxString m_fileName; // for basic inscriptions
|
wxString m_fileName; // for basic inscriptions
|
||||||
const wxString* m_sheetFullName; // for basic inscriptions
|
wxString m_sheetFullName; // for basic inscriptions
|
||||||
const wxString* m_sheetLayer; // for basic inscriptions
|
const wxString* m_sheetLayer; // for basic inscriptions
|
||||||
|
|
||||||
|
|
||||||
|
@ -400,10 +400,9 @@ public:
|
||||||
m_penSize = 1;
|
m_penSize = 1;
|
||||||
m_sheetNumber = 1;
|
m_sheetNumber = 1;
|
||||||
m_sheetCount = 1;
|
m_sheetCount = 1;
|
||||||
m_sheetLayer = 0;
|
m_sheetLayer = nullptr;
|
||||||
m_titleBlock = NULL;
|
m_titleBlock = nullptr;
|
||||||
m_paperFormat = NULL;
|
m_paperFormat = nullptr;
|
||||||
m_sheetFullName = NULL;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
~WS_DRAW_ITEM_LIST()
|
~WS_DRAW_ITEM_LIST()
|
||||||
|
@ -427,7 +426,7 @@ public:
|
||||||
*/
|
*/
|
||||||
void SetSheetName( const wxString& aSheetName )
|
void SetSheetName( const wxString& aSheetName )
|
||||||
{
|
{
|
||||||
m_sheetFullName = &aSheetName;
|
m_sheetFullName = aSheetName;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue