Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
blender-addons
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
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
blender
blender-addons
Commits
ed7ed429
Commit
ed7ed429
authored
Jan 1, 2021
by
Vilém Duha
Browse files
Options
Downloads
Patches
Plain Diff
BlenderKit: fix typos, reenable icon in profile panel
parent
59f60554
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
blenderkit/bkit_oauth.py
+3
-3
3 additions, 3 deletions
blenderkit/bkit_oauth.py
blenderkit/ui.py
+7
-5
7 additions, 5 deletions
blenderkit/ui.py
blenderkit/ui_panels.py
+4
-4
4 additions, 4 deletions
blenderkit/ui_panels.py
with
14 additions
and
12 deletions
blenderkit/bkit_oauth.py
+
3
−
3
View file @
ed7ed429
...
@@ -188,7 +188,7 @@ class CancelLoginOnline(bpy.types.Operator):
...
@@ -188,7 +188,7 @@ class CancelLoginOnline(bpy.types.Operator):
return
{
'
FINISHED
'
}
return
{
'
FINISHED
'
}
classes
s
=
(
classes
=
(
RegisterLoginOnline
,
RegisterLoginOnline
,
CancelLoginOnline
,
CancelLoginOnline
,
Logout
,
Logout
,
...
@@ -196,10 +196,10 @@ classess = (
...
@@ -196,10 +196,10 @@ classess = (
def
register
():
def
register
():
for
c
in
classes
s
:
for
c
in
classes
:
bpy
.
utils
.
register_class
(
c
)
bpy
.
utils
.
register_class
(
c
)
def
unregister
():
def
unregister
():
for
c
in
classes
s
:
for
c
in
classes
:
bpy
.
utils
.
unregister_class
(
c
)
bpy
.
utils
.
unregister_class
(
c
)
This diff is collapsed.
Click to expand it.
blenderkit/ui.py
+
7
−
5
View file @
ed7ed429
...
@@ -30,10 +30,11 @@ if "bpy" in locals():
...
@@ -30,10 +30,11 @@ if "bpy" in locals():
bg_blender
=
importlib
.
reload
(
bg_blender
)
bg_blender
=
importlib
.
reload
(
bg_blender
)
colors
=
importlib
.
reload
(
colors
)
colors
=
importlib
.
reload
(
colors
)
tasks_queue
=
importlib
.
reload
(
tasks_queue
)
tasks_queue
=
importlib
.
reload
(
tasks_queue
)
tasks_queue
=
importlib
.
reload
(
ui_panels
)
ui_panels
=
importlib
.
reload
(
ui_panels
)
icons
=
importlib
.
reload
(
icons
)
else
:
else
:
from
blenderkit
import
paths
,
ratings
,
utils
,
search
,
upload
,
ui_bgl
,
download
,
bg_blender
,
colors
,
tasks_queue
,
\
from
blenderkit
import
paths
,
ratings
,
utils
,
search
,
upload
,
ui_bgl
,
download
,
bg_blender
,
colors
,
tasks_queue
,
\
ui_panels
ui_panels
,
icons
import
bpy
import
bpy
...
@@ -1834,8 +1835,9 @@ class RunAssetBarWithContext(bpy.types.Operator):
...
@@ -1834,8 +1835,9 @@ class RunAssetBarWithContext(bpy.types.Operator):
return
{
'
FINISHED
'
}
return
{
'
FINISHED
'
}
classes
s
=
(
classes
=
(
AssetBarOperator
,
AssetBarOperator
,
# AssetBarExperiment,
RunAssetBarWithContext
,
RunAssetBarWithContext
,
TransferBlenderkitData
,
TransferBlenderkitData
,
UndoWithContext
,
UndoWithContext
,
...
@@ -1858,7 +1860,7 @@ def pre_load(context):
...
@@ -1858,7 +1860,7 @@ def pre_load(context):
def
register_ui
():
def
register_ui
():
global
handler_2d
,
handler_3d
global
handler_2d
,
handler_3d
for
c
in
classes
s
:
for
c
in
classes
:
bpy
.
utils
.
register_class
(
c
)
bpy
.
utils
.
register_class
(
c
)
args
=
(
None
,
bpy
.
context
)
args
=
(
None
,
bpy
.
context
)
...
@@ -1893,7 +1895,7 @@ def unregister_ui():
...
@@ -1893,7 +1895,7 @@ def unregister_ui():
bpy
.
types
.
SpaceView3D
.
draw_handler_remove
(
handler_2d
,
'
WINDOW
'
)
bpy
.
types
.
SpaceView3D
.
draw_handler_remove
(
handler_2d
,
'
WINDOW
'
)
bpy
.
types
.
SpaceView3D
.
draw_handler_remove
(
handler_3d
,
'
WINDOW
'
)
bpy
.
types
.
SpaceView3D
.
draw_handler_remove
(
handler_3d
,
'
WINDOW
'
)
for
c
in
classes
s
:
for
c
in
classes
:
bpy
.
utils
.
unregister_class
(
c
)
bpy
.
utils
.
unregister_class
(
c
)
wm
=
bpy
.
context
.
window_manager
wm
=
bpy
.
context
.
window_manager
...
...
This diff is collapsed.
Click to expand it.
blenderkit/ui_panels.py
+
4
−
4
View file @
ed7ed429
...
@@ -564,7 +564,7 @@ class VIEW3D_PT_blenderkit_profile(Panel):
...
@@ -564,7 +564,7 @@ class VIEW3D_PT_blenderkit_profile(Panel):
row
=
layout
.
row
()
row
=
layout
.
row
()
row
.
label
(
text
=
'
My plan:
'
)
row
.
label
(
text
=
'
My plan:
'
)
row
.
label
(
text
=
'
%s plan
'
%
pn
)
#
, icon_value=my_icon.icon_id)
row
.
label
(
text
=
'
%s plan
'
%
pn
,
icon_value
=
my_icon
.
icon_id
)
if
pn
==
'
Free
'
:
if
pn
==
'
Free
'
:
layout
.
operator
(
"
wm.url_open
"
,
text
=
"
Change plan
"
,
layout
.
operator
(
"
wm.url_open
"
,
text
=
"
Change plan
"
,
icon
=
'
URL
'
).
url
=
paths
.
get_bkit_url
()
+
paths
.
BLENDERKIT_PLANS
icon
=
'
URL
'
).
url
=
paths
.
get_bkit_url
()
+
paths
.
BLENDERKIT_PLANS
...
@@ -1597,7 +1597,7 @@ def header_search_draw(self, context):
...
@@ -1597,7 +1597,7 @@ def header_search_draw(self, context):
# however in this example we only store "main"
# however in this example we only store "main"
preview_collections
=
{}
preview_collections
=
{}
classes
s
=
(
classes
=
(
SetCategoryOperator
,
SetCategoryOperator
,
VIEW3D_PT_blenderkit_profile
,
VIEW3D_PT_blenderkit_profile
,
VIEW3D_PT_blenderkit_login
,
VIEW3D_PT_blenderkit_login
,
...
@@ -1619,13 +1619,13 @@ classess = (
...
@@ -1619,13 +1619,13 @@ classess = (
def
register_ui_panels
():
def
register_ui_panels
():
for
c
in
classes
s
:
for
c
in
classes
:
bpy
.
utils
.
register_class
(
c
)
bpy
.
utils
.
register_class
(
c
)
bpy
.
types
.
VIEW3D_MT_editor_menus
.
append
(
header_search_draw
)
bpy
.
types
.
VIEW3D_MT_editor_menus
.
append
(
header_search_draw
)
def
unregister_ui_panels
():
def
unregister_ui_panels
():
bpy
.
types
.
VIEW3D_MT_editor_menus
.
remove
(
header_search_draw
)
bpy
.
types
.
VIEW3D_MT_editor_menus
.
remove
(
header_search_draw
)
for
c
in
classes
s
:
for
c
in
classes
:
# print('unregister', c)
# print('unregister', c)
bpy
.
utils
.
unregister_class
(
c
)
bpy
.
utils
.
unregister_class
(
c
)
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