1 implementation of InTransaction
System.Windows.Forms.Design (1)
System\ComponentModel\Design\DesignerHost.cs (1)
869bool IDesignerHost.InTransaction => (_transactions is not null && _transactions.Count > 0) || IsClosingTransaction;
36 references to InTransaction
System.Windows.Forms.Design (11)
System\ComponentModel\Design\DesignerActionUI.cs (2)
280if (host is { InTransaction: true } and not IDesignerHostTransactionState { IsClosingTransaction: true }) 538if (_serviceProvider.TryGetService(out IDesignerHost? host) && host.InTransaction)
System\ComponentModel\Design\DesignerEventService.cs (2)
262if (host.InTransaction) 289if (host.InTransaction)
System\ComponentModel\Design\DesignerHost.cs (1)
1012if (((IDesignerHost)this).InTransaction)
System\ComponentModel\Design\SelectionService.cs (2)
73if (host.InTransaction) 277if (host.InTransaction)
System\ComponentModel\Design\UndoEngine.cs (1)
157if (reason != PopUnitReason.Normal || !_host.InTransaction)
System\Windows\Forms\Design\Behavior\SelectionManager.cs (1)
289if (!_designerHost.InTransaction)
System\Windows\Forms\Design\SelectionUIService.cs (2)
81if (host.InTransaction) 157if (_host.InTransaction)
System.Windows.Forms.Design.Tests (25)
System\ComponentModel\Design\DesignerHostTests.cs (11)
82Assert.False(host.InTransaction); 1875Assert.True(host.InTransaction); 1882Assert.True(host.InTransaction); 1900Assert.True(host.InTransaction); 1907Assert.True(host.InTransaction); 1975Assert.True(host.InTransaction); 1986Assert.True(host.InTransaction); 1997Assert.False(host.InTransaction); 2088Assert.True(host.InTransaction); 2099Assert.True(host.InTransaction); 2110Assert.False(host.InTransaction);
System\ComponentModel\Design\DesignSurfaceTests.cs (14)
24Assert.False(surface.Host.InTransaction); 63Assert.False(surface.Host.InTransaction); 85Assert.False(surface.Host.InTransaction); 107Assert.False(surface.Host.InTransaction); 154Assert.False(surface.Host.InTransaction); 1212Assert.True(host.InTransaction); 1216Assert.True(host.InTransaction); 1222Assert.True(host.InTransaction); 1331Assert.True(host.InTransaction); 1335Assert.True(host.InTransaction); 1341Assert.True(host.InTransaction); 1356Assert.True(host.InTransaction); 1360Assert.True(host.InTransaction); 1366Assert.True(host.InTransaction);