Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
blender-addons-contrib
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
blender
blender-addons-contrib
Commits
c7425abe
Commit
c7425abe
authored
14 years ago
by
Campbell Barton
Browse files
Options
Downloads
Patches
Plain Diff
fix for md3 menu
parent
2405c3c5
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
io_export_md3.py
+2
-2
2 additions, 2 deletions
io_export_md3.py
text_editor_pasteall.py
+3
-3
3 additions, 3 deletions
text_editor_pasteall.py
with
5 additions
and
5 deletions
io_export_md3.py
+
2
−
2
View file @
c7425abe
...
@@ -684,7 +684,7 @@ class ExportMD3(bpy.types.Operator):
...
@@ -684,7 +684,7 @@ class ExportMD3(bpy.types.Operator):
return
context
.
active_object
is
not
None
return
context
.
active_object
is
not
None
def
menu_func
(
self
,
context
):
def
menu_func
(
self
,
context
):
newpath
=
os
.
path
.
splitext
(
bpy
.
context
.
main
.
filepath
)[
0
]
+
"
.md3
"
newpath
=
os
.
path
.
splitext
(
bpy
.
context
.
blend_data
.
filepath
)[
0
]
+
"
.md3
"
self
.
layout
.
operator
(
ExportMD3
.
bl_idname
,
text
=
"
Quake Model 3 (.md3)
"
).
filepath
=
newpath
self
.
layout
.
operator
(
ExportMD3
.
bl_idname
,
text
=
"
Quake Model 3 (.md3)
"
).
filepath
=
newpath
def
register
():
def
register
():
...
@@ -694,4 +694,4 @@ def unregister():
...
@@ -694,4 +694,4 @@ def unregister():
bpy
.
types
.
INFO_MT_file_export
.
remove
(
menu_func
)
bpy
.
types
.
INFO_MT_file_export
.
remove
(
menu_func
)
if
__name__
==
"
__main__
"
:
if
__name__
==
"
__main__
"
:
register
()
register
()
\ No newline at end of file
This diff is collapsed.
Click to expand it.
text_editor_pasteall.py
+
3
−
3
View file @
c7425abe
...
@@ -82,7 +82,7 @@ class PasteAllOperator(bpy.types.Operator):
...
@@ -82,7 +82,7 @@ class PasteAllOperator(bpy.types.Operator):
# get the selected text
# get the selected text
text
=
self
.
get_selected_text
(
st
.
text
)
text
=
self
.
get_selected_text
(
st
.
text
)
# if no text is selected send the whole file
# if no text is selected send the whole file
if
text
==
None
:
text
=
st
.
text
.
as_string
()
if
text
is
None
:
text
=
st
.
text
.
as_string
()
# get the file type based on the extension
# get the file type based on the extension
format
=
self
.
get_file_format
(
st
.
text
)
format
=
self
.
get_file_format
(
st
.
text
)
...
@@ -90,14 +90,14 @@ class PasteAllOperator(bpy.types.Operator):
...
@@ -90,14 +90,14 @@ class PasteAllOperator(bpy.types.Operator):
# send the text and receive the returned page
# send the text and receive the returned page
html
=
self
.
send_text
(
text
,
format
)
html
=
self
.
send_text
(
text
,
format
)
if
html
==
None
:
if
html
is
None
:
self
.
report
(
'
ERROR
'
,
"
Error in sending the text to the server.
"
)
self
.
report
(
'
ERROR
'
,
"
Error in sending the text to the server.
"
)
return
{
'
CANCELLED
'
}
return
{
'
CANCELLED
'
}
# get the link of the posted page
# get the link of the posted page
page
=
self
.
get_page
(
str
(
html
))
page
=
self
.
get_page
(
str
(
html
))
if
page
==
None
or
page
==
""
:
if
page
is
None
or
page
==
""
:
self
.
report
(
'
ERROR
'
,
"
Error in retrieving the page.
"
)
self
.
report
(
'
ERROR
'
,
"
Error in retrieving the page.
"
)
return
{
'
CANCELLED
'
}
return
{
'
CANCELLED
'
}
else
:
else
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment