当前位置: 首页>>代码示例>>C#>>正文


C# IWindowManager类代码示例

本文整理汇总了C#中IWindowManager的典型用法代码示例。如果您正苦于以下问题:C# IWindowManager类的具体用法?C# IWindowManager怎么用?C# IWindowManager使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


IWindowManager类属于命名空间,在下文中一共展示了IWindowManager类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: StockMinListadoViewModel

        public StockMinListadoViewModel(IWindowManager windowmanager)
        {
            _windowManager = windowmanager;
            Usuario u = new Usuario();
            u = DataObjects.Seguridad.UsuarioSQL.buscarUsuarioPorIdUsuario(Int32.Parse(Thread.CurrentPrincipal.Identity.Name));
            idTienda = u.IdTienda;
            idResponsable = u.IdUsuario;

            if (idTienda > 0) Enable = false;
            else Enable = true;

            Tienda central = new Tienda();
            central.Nombre = "ALMACEN CENTRAL";
            central.IdTienda = 0;

            TiendaSQL tSQL = new TiendaSQL();
            CmbTiendas = tSQL.BuscarTienda();
            CmbTiendas.Insert(0, central);

            Index = this.CmbTiendas.FindIndex(x => x.IdTienda == idTienda);

            if (idTienda > 0)
            {
                ProductoSQL pSQL = new ProductoSQL();
                LstProductos = pSQL.BuscarProductoxTienda(idTienda, true);
            }
            else
            {
                ProductoSQL pSQL = new ProductoSQL();
                LstProductos = pSQL.BuscarProductoxCentral(1,-1, true);
            }
        }
开发者ID:alfonsobp,项目名称:made-in-house,代码行数:32,代码来源:StockMinListadoViewModel.cs

示例2: MainViewModel

        public MainViewModel(IEventAggregator eventAggregator, IWindowManager windowManager)
        {
            _eventAggregator = eventAggregator;
            _windowManager = windowManager;

            base.DisplayName = "Open Serial Port Monitor";// +Assembly.GetExecutingAssembly().GetName().Version;
        }
开发者ID:whitestone-no,项目名称:open-serial-port-monitor,代码行数:7,代码来源:MainViewModel.cs

示例3: DocumentViewModel

        public DocumentViewModel(
            IDialogService dialogService,
            IWindowManager windowManager,
            ISiteContextGenerator siteContextGenerator,
            Func<string, IMetaWeblogService> getMetaWeblog,
            ISettingsProvider settingsProvider,
            IDocumentParser documentParser)
        {
            this.dialogService = dialogService;
            this.windowManager = windowManager;
            this.siteContextGenerator = siteContextGenerator;
            this.getMetaWeblog = getMetaWeblog;
            this.settingsProvider = settingsProvider;
            this.documentParser = documentParser;

            FontSize = GetFontSize();

            title = "New Document";
            Original = "";
            Document = new TextDocument();
            Post = new Post();
            timer = new DispatcherTimer();
            timer.Tick += TimerTick;
            timer.Interval = delay;
        }
开发者ID:larsw,项目名称:DownmarkerWPF,代码行数:25,代码来源:DocumentViewModel.cs

示例4: MainController

        public MainController(MainWindow window, 
            IWindowManager windowManager,
            IStoredClassDataPresenter storedClassDataPresenter,
            IConnectionPresenter connectionPresenter,
            IStoredClassPresenter storedClassPresenter,
            IFieldPresenter fieldPresenter,
            IFieldListPresenter fieldListPresenter,
            IConnectionStatisticsPresenter connectionStatisticsPresenter
            )
        {
            this.window = window;
            this.windowManager = windowManager;
            this.storedClassDataPresenter = storedClassDataPresenter;
            this.connectionPresenter = connectionPresenter;
            this.storedClassPresenter = storedClassPresenter;

            this.window.explorer.ShowDataFired += storedClassDataPresenter.ShowData;
            this.window.explorer.ShowFieldsFired += fieldListPresenter.ShowFields;
            this.window.AddNewConnectionFired += this.connectionPresenter.AddNew;

            this.window.explorer.EditConnectionFired += this.connectionPresenter.Edit;
            this.window.explorer.DeleteConnectionFired += this.connectionPresenter.Delete;
            this.window.explorer.RenameClassFired += storedClassPresenter.RenameClass;
            this.window.explorer.RenameFieldFired += fieldPresenter.RenameField;
            this.window.explorer.ShowStatisticsFired += connectionStatisticsPresenter.Show;
            this.window.explorer.CreateNewStoredClassFired += storedClassPresenter.CreateNew;
        }
开发者ID:vansickle,项目名称:dbexplorer,代码行数:27,代码来源:MainController.cs

示例5: DevolucionesRegistrarViewModel

 public DevolucionesRegistrarViewModel(IWindowManager windowmanager, DevolucionesBuscarViewModel window, int idDevolucion = -1)
 {
     _windowManager = windowmanager;
     this.window = window;
     if (idDevolucion > 0)
     {
         this.idDevolucion = idDevolucion;
         this.ObtenerProductosVenta();
         IndMantenimiento = DETALLE;
         IsReadOnly = true;
         if ((new DevolucionSQL()).puedeAnular(idDevolucion))
             CanDelete = Visibility.Visible;
         else
             CanDelete = Visibility.Collapsed;
         CanSave = Visibility.Collapsed;
         ViewDni = Visibility.Collapsed;
     }
     else
     {
         IndMantenimiento = REGISTRO;
         IsReadOnly = false;
         CanDelete = Visibility.Collapsed;
         CanSave = Visibility.Visible;
         ViewDni = Visibility.Visible;
     }
 }
开发者ID:alfonsobp,项目名称:made-in-house,代码行数:26,代码来源:DevolucionesRegistrarViewModel.cs

示例6: MantenerNotaDeIngresoViewModel

        public MantenerNotaDeIngresoViewModel(IWindowManager windowmanager)
        {
            _windowManager = windowmanager;
            pxaSQL = new ProductoSQL();
            this.cmbMotivo = DataObjects.Almacen.MotivoSQL.BuscarMotivos(1);
            AlmacenSQL aGW = new AlmacenSQL();
            u = DataObjects.Seguridad.UsuarioSQL.buscarUsuarioPorIdUsuario(Int32.Parse(Thread.CurrentPrincipal.Identity.Name));
            idTienda = u.IdTienda;
            Models.Almacen.Almacenes a;
            if (idTienda != 0)
            {
                //1 deposito
                //2 anaquel
                //3 central va al else
                a = aGW.BuscarAlmacen(-1, idTienda, 1);
            }
            else
            {
                a = aGW.BuscarAlmacen(-1, -1, 3);
            }

            List<Usuario> ul = new List<Usuario>();
            ul.Add(u);
            this.responsable = new List<Usuario>(ul);

            List<Models.Almacen.Almacenes> al = new List<Models.Almacen.Almacenes>();
            al.Add(a);
            this.almacen = al;
            Estado = true;
            EstadoMot = true;
            EstadoPro = true;
        }
开发者ID:alfonsobp,项目名称:made-in-house,代码行数:32,代码来源:MantenerNotaDeIngresoViewModel.cs

示例7: Execute

        public void Execute(IWindowManager windowManager, IQuestionDialog questionDialog)
        {
            var question = new Question(
                null,
                Text,
                _possibleAnswers
                );

            questionDialog.Setup(
                Caption,
                new[] {question}
                );

            questionDialog.WasShutdown += delegate{
                if(_handleResult != null)
                    _handleResult(question.Answer);
                else if(question.Answer == Answer.No || question.Answer == Answer.Cancel)
                {
                    Completed(this, new CancelResult());
                    return;
                }

                Completed(this, null);
            };

            windowManager.ShowDialog(questionDialog, null, null);
        }
开发者ID:Buthrakaur,项目名称:WpfModularApp,代码行数:27,代码来源:MessageBoxResult.cs

示例8: ShellViewModel

        public ShellViewModel(
            Func<HintSession, OverlayViewModel> overlayFactory,
            Func<HintSession, DebugOverlayViewModel> debugOverlayFactory,
            IHintProviderService hintProviderService,
            IDebugHintProviderService debugHintProviderService,
            IWindowManager windowManager,
            Func<OptionsViewModel> optionsVmFactory,
            IKeyListenerService keyListener)
        {
            _overlayFactory = overlayFactory;
            _debugOverlayFactory = debugOverlayFactory;
            _keyListener = keyListener;
            _windowManager = windowManager;
            _hintProviderService = hintProviderService;
            _debugHintProviderService = debugHintProviderService;
            _optionsVmFactory = optionsVmFactory;

            _keyListener.HotKey = new HotKey
            {
                Keys = Keys.OemSemicolon,
                Modifier = KeyModifier.Alt
            };

            #if DEBUG
            _keyListener.DebugHotKey = new HotKey
            {
                Keys = Keys.OemSemicolon,
                Modifier = KeyModifier.Alt | KeyModifier.Shift
            };
            #endif

            _keyListener.OnHotKeyActivated += _keyListener_OnHotKeyActivated;
            _keyListener.OnDebugHotKeyActivated += _keyListener_OnDebugHotKeyActivated;
        }
开发者ID:arizzubair,项目名称:hunt-and-peck,代码行数:34,代码来源:ShellViewModel.cs

示例9: NotifyIconViewModel

        public NotifyIconViewModel(
            IWindowManager windowManager,
            ISyncThingManager syncThingManager,
            Func<SettingsViewModel> settingsViewModelFactory,
            IProcessStartProvider processStartProvider,
            FileTransfersTrayViewModel fileTransfersViewModel)
        {
            this.windowManager = windowManager;
            this.syncThingManager = syncThingManager;
            this.settingsViewModelFactory = settingsViewModelFactory;
            this.processStartProvider = processStartProvider;
            this.FileTransfersViewModel = fileTransfersViewModel;

            this.syncThingManager.StateChanged += (o, e) =>
            {
                this.SyncThingState = e.NewState;
                if (e.NewState != SyncThingState.Running)
                    this.SyncThingSyncing = false; // Just make sure we reset this...
            };
            this.SyncThingState = this.syncThingManager.State;

            this.syncThingManager.TotalConnectionStatsChanged += (o, e) =>
            {
                var stats = e.TotalConnectionStats;
                this.SyncThingSyncing = stats.InBytesPerSecond > 0 || stats.OutBytesPerSecond > 0;
            };

            this.syncThingManager.DataLoaded += (o, e) =>
            {
                this.Folders = new BindableCollection<FolderViewModel>(this.syncThingManager.Folders.FetchAll()
                    .Select(x => new FolderViewModel(x, this.processStartProvider))
                    .OrderBy(x => x.FolderId));
            };
        }
开发者ID:RipleyBooya,项目名称:SyncTrayzor,代码行数:34,代码来源:NotifyIconViewModel.cs

示例10: MantenerGuiaDeRemisionViewModel

        public MantenerGuiaDeRemisionViewModel(IWindowManager windowmanager, GuiaRemision g)
            : this(windowmanager)
        {
            if (g.Nota != null)
            {
                Nota = g.Nota;
                Alm = g.Almacen;
            }

            if (g.Orden != null)
            {
                Orden = g.Orden;
                Orden.CodOrden = "OD-" + (1000000 + Orden.IdOrdenDespacho).ToString();
            }

            TxtCodigo = g.CodGuiaRem;
            TxtFechaReg = g.FechaReg;
            SeleccionadoTipo=g.Tipo;
            TxtConductor = g.Conductor;
            SeleccionadoCamion = g.Camion;
            TxtObservaciones = g.Observaciones;

            if (g.Estado == 1)
                TxtEstado = "EMITIDA";
            else
                TxtEstado = "ATENDIDA";

            indicador = 2;
        }
开发者ID:alfonsobp,项目名称:made-in-house,代码行数:29,代码来源:MantenerGuiaDeRemisionViewModel.cs

示例11: BuscarZonaViewModel

        public BuscarZonaViewModel(IWindowManager windowmanager)
        {
            _windowManager = windowmanager;
            Usuario u = new Usuario();
            u = DataObjects.Seguridad.UsuarioSQL.buscarUsuarioPorIdUsuario(Int32.Parse(Thread.CurrentPrincipal.Identity.Name));
            idTienda = u.IdTienda;
            idResponsable = u.IdUsuario;

            TiendaSQL tSQL = new TiendaSQL();
            CmbTiendas = tSQL.BuscarTienda();
            Index = this.CmbTiendas.FindIndex(x => x.IdTienda == idTienda);

            AlmacenSQL aSQL = new AlmacenSQL();
            Almacenes anaquel = aSQL.BuscarAlmacen(-1, idTienda, 2);

            idAnaquel = anaquel.IdAlmacen;

            NumColumns = anaquel.NroColumnas;
            NumRows = anaquel.NroFilas;
            Altura = anaquel.Altura;

            TipoZonaSQL tzSQL = new TipoZonaSQL();
            LstZonasAnq = tzSQL.ObtenerZonasxAlmacen(idAnaquel, 2);
            CmbZonas = lstZonasAnq;
            ProductoSQL pSQL = new ProductoSQL();
            LstProductos = pSQL.BuscarProductoxTienda(idTienda);
        }
开发者ID:alfonsobp,项目名称:made-in-house,代码行数:27,代码来源:BuscarZonaViewModel.cs

示例12: ShellViewModel

        public ShellViewModel(IWindowManager window, IEventAggregator events)
        {
            _window = window;
            _events = events;

            DisplayName = "NXT Remote Control";
        }
开发者ID:wortexx,项目名称:NxtRemoteControl,代码行数:7,代码来源:ShellViewModel.cs

示例13: AppViewModel

        public AppViewModel(IWindowManager windowManager)
        {
            _windowManager = windowManager;

            // Init children view models.
            SettingsViewModel = new SettingsViewModel(_windowManager);
        }
开发者ID:dddbliss,项目名称:seeker,代码行数:7,代码来源:AppViewModel.cs

示例14: ConsultaProdutoViewModel

        public ConsultaProdutoViewModel(IWindowManager windowManager)
        {
            _windowManager = windowManager;
            DisplayName = "Consulta de Produtos";

            Consultar();
        }
开发者ID:zizuiZ,项目名称:petshop_pss_bkp,代码行数:7,代码来源:ConsultaProdutoViewModel.cs

示例15: SimulationView

		public SimulationView (Context context, SensorManager sensorManager, IWindowManager window)
			: base (context)
		{
			Bounds = new PointF ();

			// Get an accelorometer sensor
			sensor_manager = sensorManager;
			accel_sensor = sensor_manager.GetDefaultSensor (SensorType.Accelerometer);

			// Calculate screen size and dpi
			var metrics = new DisplayMetrics ();
			window.DefaultDisplay.GetMetrics (metrics);

			meters_to_pixels_x = metrics.Xdpi / 0.0254f;
			meters_to_pixels_y = metrics.Ydpi / 0.0254f;

			// Rescale the ball so it's about 0.5 cm on screen
			var ball = BitmapFactory.DecodeResource (Resources, Resource.Drawable.Ball);
			var dest_w = (int)(BALL_DIAMETER * meters_to_pixels_x + 0.5f);
			var dest_h = (int)(BALL_DIAMETER * meters_to_pixels_y + 0.5f);
			ball_bitmap = Bitmap.CreateScaledBitmap (ball, dest_w, dest_h, true);

			// Load the wood background texture
			var opts = new BitmapFactory.Options ();
			opts.InDither = true;
			opts.InPreferredConfig = Bitmap.Config.Rgb565;
			wood_bitmap = BitmapFactory.DecodeResource (Resources, Resource.Drawable.Wood, opts);
			wood_bitmap2 = BitmapFactory.DecodeResource (Resources, Resource.Drawable.Wood, opts);

			display = window.DefaultDisplay;
			particles = new ParticleSystem (this);
		}
开发者ID:CHANDAN145,项目名称:monodroid-samples,代码行数:32,代码来源:SimulationView.cs


注:本文中的IWindowManager类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。