mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-17 14:02:27 +00:00
applyed the patch by Bruno Postle
This commit is contained in:
committed by
Dion Moult
parent
b2d7fb9443
commit
72dae8e9ad
@@ -33,15 +33,15 @@ from . import ui, prop, operator
|
|||||||
# }
|
# }
|
||||||
|
|
||||||
classes = (
|
classes = (
|
||||||
operators.AddFileToRepo,
|
operator.AddFileToRepo,
|
||||||
operators.CommitChanges,
|
operator.CommitChanges,
|
||||||
operators.CreateRepo,
|
operator.CreateRepo,
|
||||||
operators.DiscardUncommitted,
|
operator.DiscardUncommitted,
|
||||||
operators.DisplayRevision,
|
operator.DisplayRevision,
|
||||||
operators.DisplayUncommitted,
|
operator.DisplayUncommitted,
|
||||||
operators.Merge,
|
operator.Merge,
|
||||||
operators.RefreshGit,
|
operator.RefreshGit,
|
||||||
operators.SwitchRevision,
|
operator.SwitchRevision,
|
||||||
prop.IfcGitListItem,
|
prop.IfcGitListItem,
|
||||||
prop.IfcGitProperties,
|
prop.IfcGitProperties,
|
||||||
ui.IFCGIT_PT_panel,
|
ui.IFCGIT_PT_panel,
|
||||||
|
|||||||
@@ -3,12 +3,7 @@ import re
|
|||||||
import bpy
|
import bpy
|
||||||
import blenderbim.core.ifcgit as core
|
import blenderbim.core.ifcgit as core
|
||||||
import blenderbim.tool as tool
|
import blenderbim.tool as tool
|
||||||
# from tool import IfcGit as tool
|
from blenderbim.bim.module.ifcgit.data import IfcGitData, refresh
|
||||||
from data import IfcGitData
|
|
||||||
|
|
||||||
# import handler
|
|
||||||
|
|
||||||
# import blenderbim.tool as tool
|
|
||||||
|
|
||||||
|
|
||||||
class CreateRepo(bpy.types.Operator):
|
class CreateRepo(bpy.types.Operator):
|
||||||
@@ -34,7 +29,7 @@ class CreateRepo(bpy.types.Operator):
|
|||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
|
|
||||||
core.create_repo(tool.IfcGit, tool.Ifc)
|
core.create_repo(tool.IfcGit, tool.Ifc)
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|
||||||
@@ -58,7 +53,7 @@ class AddFileToRepo(bpy.types.Operator):
|
|||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
|
|
||||||
core.add_file(tool.IfcGit, tool.Ifc)
|
core.add_file(tool.IfcGit, tool.Ifc)
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|
||||||
@@ -72,7 +67,7 @@ class DiscardUncommitted(bpy.types.Operator):
|
|||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
|
|
||||||
core.discard_uncomitted(tool.IfcGit, tool.Ifc)
|
core.discard_uncomitted(tool.IfcGit, tool.Ifc)
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|
||||||
@@ -107,7 +102,7 @@ class CommitChanges(bpy.types.Operator):
|
|||||||
|
|
||||||
repo = IfcGitData.data["repo"]
|
repo = IfcGitData.data["repo"]
|
||||||
core.commit_changes(tool.IfcGit, tool.Ifc, repo, context)
|
core.commit_changes(tool.IfcGit, tool.Ifc, repo, context)
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|
||||||
@@ -129,7 +124,7 @@ class RefreshGit(bpy.types.Operator):
|
|||||||
|
|
||||||
repo = IfcGitData.data["repo"]
|
repo = IfcGitData.data["repo"]
|
||||||
core.refresh_revision_list(tool.IfcGit, repo, tool.Ifc)
|
core.refresh_revision_list(tool.IfcGit, repo, tool.Ifc)
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|
||||||
@@ -143,7 +138,7 @@ class DisplayRevision(bpy.types.Operator):
|
|||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
|
|
||||||
core.colourise_revision(tool.IfcGit, context)
|
core.colourise_revision(tool.IfcGit, context)
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|
||||||
@@ -158,7 +153,7 @@ class DisplayUncommitted(bpy.types.Operator):
|
|||||||
|
|
||||||
repo = IfcGitData.data["repo"]
|
repo = IfcGitData.data["repo"]
|
||||||
core.colourise_uncommitted(tool.IfcGit, tool.Ifc, repo)
|
core.colourise_uncommitted(tool.IfcGit, tool.Ifc, repo)
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|
||||||
@@ -172,7 +167,7 @@ class SwitchRevision(bpy.types.Operator):
|
|||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
|
|
||||||
core.switch_revision(tool.IfcGit, tool.Ifc)
|
core.switch_revision(tool.IfcGit, tool.Ifc)
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|
||||||
@@ -192,7 +187,7 @@ class Merge(bpy.types.Operator):
|
|||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
|
|
||||||
if core.merge_branch(tool.IfcGit, tool.Ifc, self):
|
if core.merge_branch(tool.IfcGit, tool.Ifc, self):
|
||||||
handler.refresh_ui_data()
|
refresh()
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
else:
|
else:
|
||||||
return {"CANCELLED"}
|
return {"CANCELLED"}
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ from bpy.props import (
|
|||||||
IntProperty,
|
IntProperty,
|
||||||
EnumProperty,
|
EnumProperty,
|
||||||
)
|
)
|
||||||
from data import IfcGitData
|
from blenderbim.bim.module.ifcgit.data import IfcGitData, refresh
|
||||||
|
|
||||||
|
|
||||||
def git_branches(self, context):
|
def git_branches(self, context):
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import bpy
|
import bpy
|
||||||
import time
|
import time
|
||||||
from data import IfcGitData
|
from blenderbim.bim.module.ifcgit.data import IfcGitData, refresh
|
||||||
|
|
||||||
|
|
||||||
class IFCGIT_PT_panel(bpy.types.Panel):
|
class IFCGIT_PT_panel(bpy.types.Panel):
|
||||||
|
|||||||
@@ -30,6 +30,8 @@ from blenderbim.tool.drawing import Drawing
|
|||||||
from blenderbim.tool.geometry import Geometry
|
from blenderbim.tool.geometry import Geometry
|
||||||
from blenderbim.tool.georeference import Georeference
|
from blenderbim.tool.georeference import Georeference
|
||||||
from blenderbim.tool.ifc import Ifc
|
from blenderbim.tool.ifc import Ifc
|
||||||
|
from blenderbim.tool.ifcgit import IfcGit
|
||||||
|
from blenderbim.tool.ifcgit import IfcGitRepo
|
||||||
from blenderbim.tool.library import Library
|
from blenderbim.tool.library import Library
|
||||||
from blenderbim.tool.loader import Loader
|
from blenderbim.tool.loader import Loader
|
||||||
from blenderbim.tool.material import Material
|
from blenderbim.tool.material import Material
|
||||||
|
|||||||
Reference in New Issue
Block a user