@@ -9435,6 +9435,26 @@ public protocol UndoManagerProtocol : AnyObject {
9435
9435
*/
9436
9436
func canUndo() -> Bool
9437
9437
9438
+ /**
9439
+ * Ends the current group, calling UndoManager::undo() after this will
9440
+ * undo all changes that occurred during the group.
9441
+ */
9442
+ func groupEnd()
9443
+
9444
+ /**
9445
+ * Will start a new group of changes, all subsequent changes will be merged
9446
+ * into a new item on the undo stack. If we receive remote changes, we determine
9447
+ * wether or not they are conflicting. If the remote changes are conflicting
9448
+ * we split the undo item and close the group. If there are no conflict
9449
+ * in changed container ids we continue the group merge.
9450
+ */
9451
+ func groupStart() throws
9452
+
9453
+ /**
9454
+ * Get the peer id of the undo manager
9455
+ */
9456
+ func peer() -> UInt64
9457
+
9438
9458
/**
9439
9459
* Record a new checkpoint.
9440
9460
*/
@@ -9574,6 +9594,39 @@ open func canUndo() -> Bool {
9574
9594
uniffi_loro_ffi_fn_method_undomanager_can_undo(self.uniffiClonePointer(),$0
9575
9595
)
9576
9596
})
9597
+ }
9598
+
9599
+ /**
9600
+ * Ends the current group, calling UndoManager::undo() after this will
9601
+ * undo all changes that occurred during the group.
9602
+ */
9603
+ open func groupEnd() {try! rustCall() {
9604
+ uniffi_loro_ffi_fn_method_undomanager_group_end(self.uniffiClonePointer(),$0
9605
+ )
9606
+ }
9607
+ }
9608
+
9609
+ /**
9610
+ * Will start a new group of changes, all subsequent changes will be merged
9611
+ * into a new item on the undo stack. If we receive remote changes, we determine
9612
+ * wether or not they are conflicting. If the remote changes are conflicting
9613
+ * we split the undo item and close the group. If there are no conflict
9614
+ * in changed container ids we continue the group merge.
9615
+ */
9616
+ open func groupStart()throws {try rustCallWithError(FfiConverterTypeLoroError.lift) {
9617
+ uniffi_loro_ffi_fn_method_undomanager_group_start(self.uniffiClonePointer(),$0
9618
+ )
9619
+ }
9620
+ }
9621
+
9622
+ /**
9623
+ * Get the peer id of the undo manager
9624
+ */
9625
+ open func peer() -> UInt64 {
9626
+ return try! FfiConverterUInt64.lift(try! rustCall() {
9627
+ uniffi_loro_ffi_fn_method_undomanager_peer(self.uniffiClonePointer(),$0
9628
+ )
9629
+ })
9577
9630
}
9578
9631
9579
9632
/**
@@ -16983,6 +17036,15 @@ private var initializationResult: InitializationResult = {
16983
17036
if (uniffi_loro_ffi_checksum_method_undomanager_can_undo() != 42348) {
16984
17037
return InitializationResult.apiChecksumMismatch
16985
17038
}
17039
+ if (uniffi_loro_ffi_checksum_method_undomanager_group_end() != 37541) {
17040
+ return InitializationResult.apiChecksumMismatch
17041
+ }
17042
+ if (uniffi_loro_ffi_checksum_method_undomanager_group_start() != 64372) {
17043
+ return InitializationResult.apiChecksumMismatch
17044
+ }
17045
+ if (uniffi_loro_ffi_checksum_method_undomanager_peer() != 45180) {
17046
+ return InitializationResult.apiChecksumMismatch
17047
+ }
16986
17048
if (uniffi_loro_ffi_checksum_method_undomanager_record_new_checkpoint() != 12209) {
16987
17049
return InitializationResult.apiChecksumMismatch
16988
17050
}
0 commit comments