diff orpg/mapper/miniatures_handler.py @ 151:06f10429eedc alpha

Traipse Alpha 'OpenRPG' {091125-00} Traipse is a distribution of OpenRPG that is designed to be easy to setup and go. Traipse also makes it easy for developers to work on code without fear of sacrifice. 'Ornery-Orc' continues the trend of 'Grumpy' and adds fixes to the code. 'Ornery-Orc's main goal is to offer more advanced features and enhance the productivity of the user. Update Summary (Cleaning up for Beta) Added Bookmarks Fix to Remote Admin Commands Minor fix to text based Server Fix to Pretty Print, from Core Fix to Splitter Nodes not being created Fix to massive amounts of images loading, from Core Added 'boot' command to remote admin Added confirmation window for sent nodes Minor changes to allow for portability to an OpenSUSE linux OS Miniatures Layer pop up box allows users to turn off Mini labels, from FlexiRPG Zoom Mouse plugin added Images added to Plugin UI Switching to Element Tree Map efficiency, from FlexiRPG Added Status Bar to Update Manager default_manifest.xml renamed to default_upmana.xml Cleaner clode for saved repositories New TrueDebug Class in orpg_log (See documentation for usage) Mercurial's hgweb folder is ported to upmana Pretty important update that can help remove thousands of dead children from your gametree. Children, <forms />, <group_atts />, <horizontal />, <cols />, <rows />, <height />, etc... are all tags now. Check your gametree and look for dead children!! New Gametree Recursion method, mapping, and context sensitivity. !Infinite Loops return error instead of freezing the software! New Syntax added for custom PC sheets Tip of the Day added, from Core and community Fixed Whiteboard ID to prevent random line or text deleting. Modified ID's to prevent non updated clients from ruining the fix.
author sirebral
date Wed, 25 Nov 2009 06:15:49 -0600
parents 54446a995007
children 537a6bbac9bd
line wrap: on
line diff
--- a/orpg/mapper/miniatures_handler.py	Tue Nov 24 17:17:42 2009 -0600
+++ b/orpg/mapper/miniatures_handler.py	Wed Nov 25 06:15:49 2009 -0600
@@ -29,16 +29,11 @@
 
 from base_handler import *
 from min_dialogs import *
-import thread
-import time
-import mimetypes
-import urllib
+import thread, time, mimetypes, urllib, wx, os
 
-import wx
 from grid import GRID_RECTANGLE
 from grid import GRID_HEXAGON
 from grid import GRID_ISOMETRIC
-import os
 
 from orpg.tools.orpg_settings import settings
 
@@ -202,7 +197,6 @@
         self.canvas.send_map_data()
         self.canvas.Refresh(False)
 
-
     def build_menu(self,label = "Miniature"):
         base_layer_handler.build_menu(self,label)
         self.main_menu.AppendSeparator()
@@ -314,8 +308,7 @@
             for item in self.mini_rclick_menu_extra_items.items(): self.min_menu.Append(item[1], item[0])
         if len(self.background_rclick_menu_extra_items)>0:
             self.main_menu.AppendSeparator()
-            for item in self.background_rclick_menu_extra_items.items():
-                self.main_menu.Append(item[1], item[0])
+            for item in self.background_rclick_menu_extra_items.items(): self.main_menu.Append(item[1], item[0])
 
     def do_min_menu(self,pos):
         self.canvas.PopupMenu(self.min_menu,pos)
@@ -620,8 +613,7 @@
         postdata = urllib.urlencode({'filename':filename, 'imgdata':imgdata, 'imgtype':imgtype})
         if self.settings.get_setting('LocalorRemote') == 'Remote':
             thread.start_new_thread(self.canvas.layers['miniatures'].upload, (postdata, filepath), {'pos':cmpPoint(x,y)})
-        else:
-            self.CherryPit(filepath, '')
+        else: self.CherryPit(filepath, '')
 
     def on_tooltip_timer(self, *args):
         pos = args[0]
@@ -634,8 +626,7 @@
             tooltip = mini_list[0].label
             #self.canvas.SetToolTipString(mini_list[0].label) 
             #Once set, it never unsets, so it sucks.
-        else:
-            self.canvas.SetToolTipString('')
+        else: self.canvas.SetToolTipString('')
 
     def on_motion(self,evt):
         if evt.Dragging() and evt.LeftIsDown():