import platform
from optparse import OptionParser
-from gui import sliceRun
+from util import sliceRun
__author__ = 'Daid'
__credits__ = """
--- /dev/null
+#This is required to workaround the python import bug where relative imports don't work if the module is imported as a main module.
+import os
+import sys
+numberOfLevelsDeepInPackageHierarchy = 1
+packageFilePath = os.path.abspath(__file__)
+for level in range( numberOfLevelsDeepInPackageHierarchy + 1 ):
+ packageFilePath = os.path.dirname( packageFilePath )
+if packageFilePath not in sys.path:
+ sys.path.insert( 0, packageFilePath )
import os, sys
import types, math
-from gui import profile
+from util import profile
from fabmetheus_utilities import archive
def DEFSET(setting):
import wx\r
import sys,math,threading,os\r
\r
-from gui import profile\r
+from util import profile\r
\r
class alterationPanel(wx.Panel):\r
def __init__(self, parent):\r
import wx, os, sys, platform, types
from gui import validators
-from gui import profile
+from util import profile
def main():
app = wx.App(False)
import wx.wizard\r
\r
from gui import machineCom\r
-from gui import profile\r
+from util import profile\r
\r
class InfoPage(wx.wizard.WizardPageSimple):\r
def __init__(self, parent, title):\r
from avr_isp import ispBase
from avr_isp import intelHex
-from gui import profile
+from util import profile
try:
import _winreg
from gui import preferencesDialog
from gui import configWizard
from gui import machineCom
-from gui import profile
from gui import printWindow
+from util import profile
def main():
app = wx.App(False)
print "Failed to find PyOpenGL: http://pyopengl.sourceforge.net/"\r
hasOpenGLlibs = False\r
\r
-from gui import profile\r
-from gui import gcodeInterpreter\r
-from gui import util3d\r
+from util import profile\r
+from util import gcodeInterpreter\r
+from util import util3d\r
\r
from fabmetheus_utilities.fabmetheus_tools import fabmetheus_interpret\r
from fabmetheus_utilities.vector3 import Vector3\r
import subprocess
import time
-from gui import sliceRun
+from util import sliceRun
class sliceProgessPanel(wx.Panel):
def __init__(self, mainWindow, parent, filename):
import types
import math
-from gui import profile
+from util import profile
SUCCESS = 0
WARNING = 1
import re
import os
-from gui import util3d
+from util import util3d
class gcodePath():
def __init__(self, newType, pathType, layerNr, startPoint):
import platform, os, subprocess, sys
from cura_sf.skeinforge_application.skeinforge_utilities import skeinforge_craft
-from gui import profile
+from util import profile
def getPyPyExe():
"Return the path to the pypy executable if we can find it. Else return False"