Resize capability for viewer.py
Brought to you by:
mbaas
Here is a patch which enables window resizing and maximizing in viewer.py.
Changes:
- added RESIZABLE flag to pygame display surface
- flags became self.flags; (width, height) became (self.width, self.height)
- handled VIDEORESIZE event, which resizes the window and updates (self.width, self.height)
Patch for adding resize capability into viewer.py
This is applied now.
I added one thing: the attributes width, height and flags are now also set in the constructor (they are just set to None). My convention is to initialize all attributes in the constructor (even though they only receive their final values later on). This is so that by looking at the constructor you will see all attributes that the class is using.