# WindowProtocolService

Roblox Engine API class from Roblox Studio 0.744.0.7441077 (version-7aaa6838d36c4448).

- Inherits from, nearest first: [Instance](https://rapi.sleaze.dev/classes/Instance.md), [Object](https://rapi.sleaze.dev/classes/Object.md)
- Tags: Not creatable, Not replicated, Service
- Memory category: Instances
- HTML page: https://rapi.sleaze.dev/classes/WindowProtocolService/
- Roblox documentation: https://create.roblox.com/docs/reference/engine/classes/WindowProtocolService

## Methods

### BeginDrag

```luau
WindowProtocolService:BeginDrag(windowId: number)
```

- Tags: Roblox script security

### Close

```luau
WindowProtocolService:Close(windowId: number)
```

- Tags: Roblox script security

### EndDrag

```luau
WindowProtocolService:EndDrag(windowId: number)
```

- Tags: Roblox script security

### GetLogicalCaptionButtonsBounds

```luau
WindowProtocolService:GetLogicalCaptionButtonsBounds(windowId: number): Rect
```

- Tags: Roblox script security

### GetNativeTitleBarControlsPosition

```luau
WindowProtocolService:GetNativeTitleBarControlsPosition(): Enum.TitleBarControlsPosition
```

- Tags: Roblox script security

### GetTitleBarMode

```luau
WindowProtocolService:GetTitleBarMode(windowId: number): Enum.TitleBarMode
```

- Tags: Roblox script security

### GetWindowState

```luau
WindowProtocolService:GetWindowState(windowId: number): Enum.WindowState
```

- Tags: Roblox script security

### IsAvailable

```luau
WindowProtocolService:IsAvailable(): boolean
```

- Tags: Roblox script security

### Maximize

```luau
WindowProtocolService:Maximize(windowId: number)
```

- Tags: Roblox script security

### Minimize

```luau
WindowProtocolService:Minimize(windowId: number)
```

- Tags: Roblox script security

### OnDragAreaDoubleClicked

```luau
WindowProtocolService:OnDragAreaDoubleClicked(windowId: number)
```

- Tags: Roblox script security

### OnDragAreaRightClicked

```luau
WindowProtocolService:OnDragAreaRightClicked(windowId: number)
```

- Tags: Roblox script security

### Restore

```luau
WindowProtocolService:Restore(windowId: number)
```

- Tags: Roblox script security

### SetCustomTitleBarHeight

```luau
WindowProtocolService:SetCustomTitleBarHeight(windowId: number, height: number)
```

- Tags: Roblox script security

### SetTitleBarMode

```luau
WindowProtocolService:SetTitleBarMode(windowId: number, mode: Enum.TitleBarMode)
```

- Tags: Roblox script security

### ShouldRenderTitleBarControlsNatively

```luau
WindowProtocolService:ShouldRenderTitleBarControlsNatively(): boolean
```

- Tags: Roblox script security

## Events

### OnWindowStateChanged

```luau
WindowProtocolService.OnWindowStateChanged: RBXScriptSignal<(windowId: number, newState: Enum.WindowState)>
```

- Tags: Roblox script security

## Inherited members

- From [Instance](https://rapi.sleaze.dev/classes/Instance.md): `Archivable`, `archivable`, `Attributes`, `AttributesReplicate`, `AttributesSerialize`, `HistoryId`, `Name`, `Parent`, `PredictionMode`, `PropertyStatusStudio`, `RobloxLocked`, `SerializedOverrides`, `SourceAssetId`, `Tags`, `UniqueId`, `numExpectedDirectChildren`, `DataCost`, `Capabilities`, `DefinesCapabilities`, `IsInSandbox`, `Sandboxed`, `AddTag`, `ClearAllChildren`, `Clone`, `Destroy`, `FindFirstAncestor`, `FindFirstAncestorOfClass`, `FindFirstAncestorWhichIsA`, `FindFirstChild`, `FindFirstChildOfClass`, `FindFirstChildWhichIsA`, `FindFirstDescendant`, `GetActor`, `GetAttribute`, `GetAttributeChangedSignal`, `GetAttributes`, `GetChildren`, `GetDebugId`, `GetDescendants`, `GetFullName`, `GetStyled`, `GetStyledPropertyChangedSignal`, `GetTags`, `HasTag`, `IsAncestorOf`, `IsDescendantOf`, `IsPropertyModified`, `QueryDescendants`, `RemoveTag`, `ResetPropertyToDefault`, `SetAttribute`, `WaitForChild`, `Remove`, `children`, `clone`, `destroy`, `findFirstChild`, `getChildren`, `isDescendantOf`, `remove`, `AncestryChanged`, `AttributeChanged`, `ChildAdded`, `ChildRemoved`, `DescendantAdded`, `DescendantRemoving`, `Destroying`, `StyledPropertiesChanged`, `childAdded`
- From [Object](https://rapi.sleaze.dev/classes/Object.md): `ClassName`, `className`, `GetPropertyChangedSignal`, `IsA`, `isA`, `Changed`
