Skip to content

Commit

Permalink
Fixed clone on NdLayout to propagate cols properly (#1739)
Browse files Browse the repository at this point in the history
  • Loading branch information
jlstevens authored and philippjfr committed Jul 31, 2017
1 parent 350b323 commit 32fe7a6
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions holoviews/core/layout.py
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,18 @@ def last(self):
return self.clone(last_items)


def clone(self, *args, **overrides):
"""
Clone method for NdLayout matches Dimensioned.clone except the
display mode is also propagated.
"""
clone = super(NdLayout, self).clone(*args, **overrides)
clone._max_cols = self._max_cols
clone.id = self.id
return clone



# To be removed after 1.3.0
class Warning(param.Parameterized): pass
collate_deprecation = Warning(name='Deprecation Warning')
Expand Down

0 comments on commit 32fe7a6

Please sign in to comment.