Exemplo n.º 1
0
        private void ToolbarItem_ShowNetworksClicked(object sender, System.Windows.RoutedEventArgs e)
        {
            if (netListView == null)
            {
                netListView         = new WinUI.NetworkListView();
                netListView.Closed += ShowNetworksClosed;
            }

            bool netListNeedsMoving = true;

            if (netListLocation.X > 0 && netListLocation.Y > 0)
            {
                netListView.Left   = netListLocation.X;
                netListView.Top    = netListLocation.Y;
                netListNeedsMoving = false;
            }

            netListView.Show();

            if (netListNeedsMoving)
            {
                setWindowPosition(netListView);
                netListLocation.X = netListView.Left;
                netListLocation.Y = netListView.Top;
            }

            netListView.Activate();
        }
Exemplo n.º 2
0
 private void ShowNetworksClosed(object sender, System.EventArgs e)
 {
     netListView = null;
 }