summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/tileset.py2
-rw-r--r--src/ui.py11
2 files changed, 10 insertions, 3 deletions
diff --git a/src/tileset.py b/src/tileset.py
index 19451de..c060f07 100644
--- a/src/tileset.py
+++ b/src/tileset.py
@@ -395,7 +395,7 @@ class KPTileset(object):
self.tiles = []
self.objects = []
- self.groupItem = KPGroupItem("")
+ self.groupItem = KPGroupItem("All Groups")
self.processImage(imageBuffer)
self.processObjects(objectBuffer, objectMetadata)
diff --git a/src/ui.py b/src/ui.py
index b581411..cc2aa0a 100644
--- a/src/ui.py
+++ b/src/ui.py
@@ -88,7 +88,6 @@ class KPObjectSelector(QtGui.QWidget):
self.sorterButton.setSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
self.sorterMenu = QtGui.QMenu()
- self.sorterMenu.setFixedWidth(self.sorterButton.width())
action = self.sorterMenu.addAction("test 1")
self.sorterButton.setMenu(self.sorterMenu)
@@ -114,9 +113,14 @@ class KPObjectSelector(QtGui.QWidget):
# Borrowed the signals and junk from Reggie, figure we'll need em'
self.listView.clicked.connect(self.handleObjReplace)
+ self.sorterMenu.aboutToShow.connect(self.fixUpMenuSize)
self.sorterMenu.triggered.connect(self.toggleTopLevel)
+ def fixUpMenuSize(self):
+ self.sorterMenu.setFixedWidth(self.sorterButton.width())
+
+
def currentSelectedObject(self):
"""Returns the currently selected object reference, for painting purposes."""
@@ -147,12 +151,15 @@ class KPObjectSelector(QtGui.QWidget):
actionMan.setData((item[1], item[2]))
+ # a Quick Fix
+ self.listView.setRowHidden(0, True)
+
def toggleTopLevel(self, action):
"""Changes the top level group in the list view."""
name = str(action.text()).strip()
- startRow = action.data().toPyObject()[0]
+ startRow = action.data().toPyObject()[0] + 1
endRow = action.data().toPyObject()[1]
for row in xrange(self.model.rowCount()):