Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(683)

Side by Side Diff: scripts/newbitmaps/bitmap_viewer

Issue 6598046: Add stuff to support new bitmap format. (Closed) Base URL: http://git.chromium.org/git/vboot_reference.git@master
Patch Set: Agree to all changes. PTAL. Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 #!/usr/bin/python -tt
2 # Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
5
6 """Quick-and-dirty viewer for bmpblock yaml files"""
7 import os
8 import sys
9 import wx
10
11 from lib import bmpblock
12 from lib import pixcontrol
13 from lib import pixdisplay
14
15 class MyApp(wx.App):
16
17 def OnInit(self):
18 self._bmpblock = bmpblock.BmpBlock(sys.argv[1])
19 progname = os.path.basename(sys.argv[0])
20 self._mainframe = pixcontrol.Frame(self._bmpblock, progname)
21 self._mainframe.Show()
22 self.SetTopWindow(self._mainframe)
23 self._imgframe = pixdisplay.Frame(self._bmpblock, sys.argv[1])
24 self._imgframe.Show()
25 return True
26
27 def main():
28 if len(sys.argv) != 2:
29 print "You must specify a config.yaml file to view"
30 sys.exit(1)
31 MyApp(False).MainLoop()
32
33 if __name__ == '__main__':
34 main()
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698