mirror of
https://github.com/TTimo/GtkRadiant.git
synced 2024-11-10 07:11:54 +00:00
cosmetic - this code isn't used anyway, surface inspector logic has moved to a plugin?
This commit is contained in:
parent
6326d84195
commit
c93f7a1ecc
2 changed files with 42 additions and 45 deletions
|
@ -273,25 +273,23 @@ static void OnCancel( GtkWidget *widget, gpointer data ){
|
|||
g_dlgSurface.HideDlg();
|
||||
}
|
||||
|
||||
static gint OnDialogKey( GtkWidget* widget, GdkEventKey* event, gpointer data ){
|
||||
if ( g_surfwin ) {
|
||||
if ( event->keyval == GDK_Return ) {
|
||||
if ( g_dlgSurface.m_bEditingTextureWidget ) {
|
||||
OnApply( NULL, NULL );
|
||||
g_dlgSurface.m_bEditingTextureWidget = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
OnDone( NULL, NULL );
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
if ( event->keyval == GDK_Escape ) {
|
||||
OnCancel( NULL, NULL );
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
return FALSE;
|
||||
static gint OnDialogKey( GtkWidget* widget, GdkEventKey* event, gpointer data ) {
|
||||
if ( g_surfwin ) {
|
||||
if ( event->keyval == GDK_Return ) {
|
||||
if ( g_dlgSurface.m_bEditingTextureWidget ) {
|
||||
OnApply( NULL, NULL );
|
||||
g_dlgSurface.m_bEditingTextureWidget = false;
|
||||
} else {
|
||||
OnDone( NULL, NULL );
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
if ( event->keyval == GDK_Escape ) {
|
||||
OnCancel( NULL, NULL );
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
// the widget can be one of hshift, vshift, hscale, vscale, rotate
|
||||
|
@ -499,7 +497,7 @@ void SurfaceDlg::InitDefaultIncrement( texdef_t *tex ){
|
|||
tex->rotate = 10;
|
||||
}
|
||||
|
||||
void SurfaceDlg::BuildDialog(){
|
||||
void SurfaceDlg::BuildDialog() {
|
||||
GtkWidget *dlg, *vbox, *hbox2, *frame, *table, *label;
|
||||
GtkWidget *button, *entry, *spin;
|
||||
|
||||
|
|
|
@ -28,42 +28,41 @@
|
|||
//#define DBG_SI 1
|
||||
#endif
|
||||
|
||||
class SurfaceDlg : public Dialog
|
||||
{
|
||||
bool m_bPatchMode;
|
||||
// brush primitive fake shift scale rot coords
|
||||
float m_shift[2];
|
||||
float m_rotate;
|
||||
float m_scale[2];
|
||||
class SurfaceDlg : public Dialog {
|
||||
bool m_bPatchMode;
|
||||
// brush primitive fake shift scale rot coords
|
||||
float m_shift[2];
|
||||
float m_rotate;
|
||||
float m_scale[2];
|
||||
|
||||
public:
|
||||
SurfaceDlg ();
|
||||
SurfaceDlg();
|
||||
|
||||
virtual void ShowDlg();
|
||||
virtual void HideDlg();
|
||||
void SetTexMods();
|
||||
void GetTexMods();
|
||||
virtual void ShowDlg();
|
||||
virtual void HideDlg();
|
||||
void SetTexMods();
|
||||
void GetTexMods();
|
||||
|
||||
void InitDefaultIncrement( texdef_t * );
|
||||
void InitDefaultIncrement( texdef_t * );
|
||||
|
||||
// Dialog Data
|
||||
int m_nHeight;
|
||||
int m_nWidth;
|
||||
// Dialog Data
|
||||
int m_nHeight;
|
||||
int m_nWidth;
|
||||
|
||||
// 0 is invalid, otherwise it's the Id of the last 'do' we are responsible for
|
||||
int m_nUndoId;
|
||||
// 0 is invalid, otherwise it's the Id of the last 'do' we are responsible for
|
||||
int m_nUndoId;
|
||||
|
||||
// is the user editing the texture widget (that changes the behaviour of 'Enter' key from OnDone to OnApply
|
||||
// reset to false at each SetTexMods or when dealing with Enter key
|
||||
bool m_bEditingTextureWidget;
|
||||
// is the user editing the texture widget (that changes the behaviour of 'Enter' key from OnDone to OnApply
|
||||
// reset to false at each SetTexMods or when dealing with Enter key
|
||||
bool m_bEditingTextureWidget;
|
||||
|
||||
protected:
|
||||
void BuildDialog();
|
||||
void BuildDialog();
|
||||
|
||||
public:
|
||||
// called to perform a fitting from the outside (shortcut key)
|
||||
void FitAll();
|
||||
GtkWidget *GetWidget(); // { return m_pWidget; }
|
||||
// called to perform a fitting from the outside (shortcut key)
|
||||
void FitAll();
|
||||
GtkWidget *GetWidget();
|
||||
};
|
||||
|
||||
#endif // _SURFACEDIALOG_H_
|
||||
|
|
Loading…
Reference in a new issue