mirror of
https://github.com/KillzXGaming/Switch-Toolbox
synced 2024-11-23 13:03:15 +00:00
32 lines
739 B
C#
32 lines
739 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel;
|
|
using System.Drawing;
|
|
using System.Data;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using System.Windows.Forms;
|
|
|
|
namespace Toolbox.Library.Forms
|
|
{
|
|
public partial class ViewportDivider : UserControl
|
|
{
|
|
public ViewportDivider()
|
|
{
|
|
InitializeComponent();
|
|
|
|
viewportPanel.Width = Runtime.ViewportEditor.Width;
|
|
}
|
|
|
|
public Viewport GetActiveViewport()
|
|
{
|
|
foreach (var control in viewportPanel.Controls)
|
|
{
|
|
if (control is Viewport)
|
|
return (Viewport)control;
|
|
}
|
|
return null;
|
|
}
|
|
}
|
|
}
|