Skip to content

Commit

Permalink
Revert "Merge pull request DynamoDS#1999 from ksobon/3dview-wrapper-2…
Browse files Browse the repository at this point in the history
…018"

This reverts commit 535c8ba.
  • Loading branch information
ZiyunShang committed Dec 7, 2018
1 parent c7f6f90 commit b09261b
Show file tree
Hide file tree
Showing 10 changed files with 531 additions and 568 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
using Autodesk.DesignScript.Runtime;
using Autodesk.Revit.DB;
using Revit.Elements.Views;
using AbstractView3D = Revit.Elements.Views.AbstractView3D;
using View3D = Revit.Elements.Views.View3D;

namespace Revit.Elements
{
Expand Down Expand Up @@ -151,14 +151,16 @@ public static WallType Wrap(Autodesk.Revit.DB.WallType ele, bool isRevitOwned)
return WallType.FromExisting(ele, isRevitOwned);
}

public static AbstractView3D Wrap(Autodesk.Revit.DB.View3D view, bool isRevitOwned)
public static View3D Wrap(Autodesk.Revit.DB.View3D view, bool isRevitOwned)
{
if (view.IsTemplate)
return Revit.Elements.Views.View3D.FromExisting(view, isRevitOwned);
if (view.IsPerspective)
return PerspectiveView.FromExisting(view, isRevitOwned);

return AxonometricView.FromExisting(view, isRevitOwned);
if (!view.IsTemplate)
{
if (view.IsPerspective)
return PerspectiveView.FromExisting(view, isRevitOwned);
else
return AxonometricView.FromExisting(view, isRevitOwned);
}
return null;
}

public static Element Wrap(Autodesk.Revit.DB.ViewPlan view, bool isRevitOwned)
Expand Down
Loading

0 comments on commit b09261b

Please sign in to comment.