summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorGlenn Smith <glenn@vector35.com>2024-02-15 15:58:14 -0500
committerPeter LaFosse <peter@vector35.com>2024-02-16 15:01:44 -0500
commite3ae076fe472e96e037f2997d9b8c6f29c4f4fce (patch)
tree13380bbe7639136845084f11ac7b168cb4010440 /python
parentf61154d607b37185d55eef52c884f35f99141303 (diff)
Add UI callback for On(Data)ViewReplaced for rebase
Diffstat (limited to 'python')
-rw-r--r--python/examples/ui_notifications.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/python/examples/ui_notifications.py b/python/examples/ui_notifications.py
index 94959217..c6809a32 100644
--- a/python/examples/ui_notifications.py
+++ b/python/examples/ui_notifications.py
@@ -66,6 +66,12 @@ class UINotification(UIContextNotification):
def OnAfterCloseFile(self, context, file, frame):
print(f"py OnAfterCloseFile {file.getFilename()} {frame.getShortFileName()}")
+ def OnViewReplaced(self, context, file, oldFrame, newFrame):
+ print(f"py OnViewReplaced {file.getFilename()} {oldFrame.getShortFileName()} -> {newFrame.getShortFileName()}")
+
+ def OnDataViewReplaced(self, context, file, oldData, newData):
+ print(f"py OnDataViewReplaced {file.getFilename()} {oldData.file.filename} -> {newData.file.filename}")
+
def OnViewChange(self, context, frame, type):
if frame:
print(f"py OnViewChange {frame.getShortFileName()} / {type}")