private void OnDropDownFloatingClicked(object sender, EventArgs e)
{
// Get the unique name of the page that needs to be converted to floating
KryptonContextMenuItem floatingItem = (KryptonContextMenuItem)sender;
string uniqueName = (string)floatingItem.Tag;
// Action depends on the current location
switch (FindPageLocation(uniqueName))
{
case DockingLocation.None:
case DockingLocation.AutoHidden:
case DockingLocation.Docked:
case DockingLocation.Navigator:
case DockingLocation.Workspace:
MakeFloatingRequest(uniqueName);
break;
case DockingLocation.Floating:
// Nothing to do, already floating
break;
}
}