Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
Printrun
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
machinery
Printrun
Commits
c2a60d20
Commit
c2a60d20
authored
May 28, 2013
by
Guillaume Seguin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cleanup loadfile(), some tabs/space mixing might explain #370
parent
27759e3f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
11 deletions
+10
-11
pronterface.py
pronterface.py
+10
-11
No files found.
pronterface.py
View file @
c2a60d20
...
...
@@ -1373,19 +1373,18 @@ class PronterWindow(MainWindow, pronsole.pronsole):
basedir
=
os
.
path
.
split
(
self
.
filename
)[
0
]
except
:
pass
dlg
=
None
dlg
=
None
if
filename
is
None
:
dlg
=
wx
.
FileDialog
(
self
,
_
(
"Open file to print"
),
basedir
,
style
=
wx
.
FD_OPEN
|
wx
.
FD_FILE_MUST_EXIST
)
dlg
.
SetWildcard
(
_
(
"OBJ, STL, and GCODE files (*.gcode;*.gco;*.g;*.stl;*.STL;*.obj;*.OBJ)|*.gcode;*.gco;*.g;*.stl;*.STL;*.obj;*.OBJ|All Files (*.*)|*.*"
))
if
(
filename
is
not
None
or
dlg
.
ShowModal
()
==
wx
.
ID_OK
)
:
if
filename
is
not
None
:
if
filename
or
dlg
.
ShowModal
()
==
wx
.
ID_OK
:
if
filename
:
name
=
filename
else
:
name
=
dlg
.
GetPath
()
if
not
(
os
.
path
.
exists
(
name
)):
self
.
status
.
SetStatusText
(
_
(
"File not found!"
))
if
dlg
is
not
None
:
dlg
.
Destroy
()
if
not
os
.
path
.
exists
(
name
):
self
.
status
.
SetStatusText
(
_
(
"File not found!"
))
return
path
=
os
.
path
.
split
(
name
)[
0
]
if
path
!=
self
.
settings
.
last_file_path
:
...
...
@@ -1407,7 +1406,7 @@ class PronterWindow(MainWindow, pronsole.pronsole):
if
self
.
p
.
online
:
wx
.
CallAfter
(
self
.
printbtn
.
Enable
)
threading
.
Thread
(
target
=
self
.
loadviz
)
.
start
()
if
dlg
is
not
Non
e
:
els
e
:
dlg
.
Destroy
()
def
loadviz
(
self
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment