mirror of
https://github.com/KillzXGaming/Switch-Toolbox
synced 2024-12-04 02:09:18 +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;
|
|
}
|
|
}
|
|
}
|