about summary refs log tree commit diff
path: root/src/game
diff options
context:
space:
mode:
authoroy <Tom_Adams@web.de>2012-01-08 01:14:52 +0100
committeroy <Tom_Adams@web.de>2012-01-08 01:14:52 +0100
commit58f57795081e677e1450844bad1043b72c7c0bea (patch)
treefbb756d481f70aadd7d898af5742ecb9871c486a /src/game
parent535324d6ed365d32c14e46f6a9f058edf99c4fd0 (diff)
downloadzcatch-58f57795081e677e1450844bad1043b72c7c0bea.tar.gz
zcatch-58f57795081e677e1450844bad1043b72c7c0bea.zip
- disabled clipping lines in the tile picker
- fixed aspect ratio of the image in the tile picker
Closes #833
Diffstat (limited to 'src/game')
-rw-r--r--src/game/editor/editor.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/game/editor/editor.cpp b/src/game/editor/editor.cpp
index 17b45bf2..c19fc86f 100644
--- a/src/game/editor/editor.cpp
+++ b/src/game/editor/editor.cpp
@@ -1641,6 +1641,12 @@ void CEditor::DoMapEditor(CUIRect View, CUIRect ToolBar)
 			pT->ShowInfo();
 		}
 	}
+	else
+	{
+		// fix aspect ratio of the image in the picker
+		float Max = min(View.w, View.h);
+		View.w = View.h = Max;
+	}
 
 	static void *s_pEditorID = (void *)&s_pEditorID;
 	int Inside = UI()->MouseInside(&View);
@@ -1965,7 +1971,7 @@ void CEditor::DoMapEditor(CUIRect View, CUIRect ToolBar)
 		}
 	}
 
-	if(GetSelectedGroup() && GetSelectedGroup()->m_UseClipping)
+	if(!m_ShowPicker && GetSelectedGroup() && GetSelectedGroup()->m_UseClipping)
 	{
 		CLayerGroup *g = m_Map.m_pGameGroup;
 		g->MapScreen();