Commit f5fd16e2 authored by g_harland's avatar g_harland
Browse files

Ooops; another file which should have been included with the last commit

parent d5b353ac
Loading
Loading
Loading
Loading
+76 −62
Original line number Diff line number Diff line
@@ -71,9 +71,11 @@ private:
	void OnApplyClick( wxCommandEvent& event );
	void UpdateLayerSettings();
	void ResetDisplayLayersCu( wxCommandEvent& event );
	DECLARE_EVENT_TABLE()

	DECLARE_EVENT_TABLE()
};


/* Table des evenements pour WinEDA_SetColorsFrame */
BEGIN_EVENT_TABLE( WinEDA_SetColorsFrame, wxDialog )
	EVT_BUTTON( ID_COLOR_RESET_SHOW_LAYER_OFF, WinEDA_SetColorsFrame::ResetDisplayLayersCu )
@@ -356,15 +358,27 @@ void WinEDA_SetColorsFrame::UpdateLayerSettings()
		}
		else
		{
//			if( laytool_list[ii]->m_Color )
//				*laytool_list[ii]->m_Color = CurrentColor[ii];

			// As there is a button associated with every layer listed
			// within this particular dialog box, the previous command
			// can be replaced with this following command.

			*laytool_list[ii]->m_Color = CurrentColor[ii];
			*laytool_list[ii]->m_NoDisplay = laytool_list[ii]->m_CheckBox->GetValue();

            // A hack, we have both g_DrawGrid and m_Parent->m_Draw_Grid.
            // A better way preferred, please.
            if( laytool_list[ii]->m_NoDisplay == &g_ShowGrid )
                m_Parent->m_Draw_Grid = g_ShowGrid;
//			if( laytool_list[ii]->m_CheckBox )
//				*laytool_list[ii]->m_NoDisplay = laytool_list[ii]->m_CheckBox->GetValue();

			// As there is a checkbox associated with every layer listed
			// within this particular dialog box, the previous command
			// can be replaced with this following command.

			*laytool_list[ii]->m_NoDisplay = laytool_list[ii]->m_CheckBox->GetValue();
		}
	}
    // Additional command required for updating visibility of grid.
    m_Parent->m_Draw_Grid = g_ShowGrid;
}