changeset 108:0c338cd2cc8e

ROMDockable: show in title bar if we're looking at the ROM's PRG or CHR This is a useful bit of information.
author Jordi Gutiérrez Hermoso <jordigh@octave.org>
date Wed, 18 Sep 2019 16:30:53 -0400
parents 06d752537e21
children e3ffae4d7528
files widgets.py
diffstat 1 files changed, 5 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/widgets.py
+++ b/widgets.py
@@ -402,9 +402,12 @@
 class ROMDockable(QW.QDockWidget):
 
     def __init__(self, filename, filetype, tile_picker):
-        super().__init__(filename.split("/")[-1])
+        rom = NES_ROM(filename)
 
-        rom = NES_ROM(filename)
+        title = filename.split("/")[-1]
+        title += " (CHR)" if rom.CHR else " (PRG)"
+
+        super().__init__(title)
 
         self.rom_canvas = ROMCanvas(rom, tile_picker)
         self.colour_picker = ColourPicker()