コード例 #1
0
        public override void Setup(ApplicationModulesManager moduleManager)
        {
            base.Setup(moduleManager);

            moduleManager.Extend(PredefinedMap.AdvBandedGridView, configuration => configuration.MapName = AdvBandedGridViewMapName);
            moduleManager.Extend(PredefinedMap.BandedGridColumn, configuration => configuration.MapName  = BandedGridColumnMapName);
            moduleManager.Extend(PredefinedMap.GridView, configuration => configuration.MapName          = GridViewMapName);
            moduleManager.ExtendMap(PredefinedMap.GridView)
            .Subscribe(_ => _.extenders.Add(_.targetInterface, typeof(IModelOptionsGridViewRules)));
            moduleManager.Extend(PredefinedMap.GridColumn, configuration => configuration.MapName = GridColumnMapName);

            moduleManager.Extend(PredefinedMap.XafLayoutControl);
            moduleManager.Extend(PredefinedMap.SplitContainerControl);
            moduleManager.Extend(PredefinedMap.LayoutView, configuration => configuration.MapName       = LayoutViewMapName);
            moduleManager.Extend(PredefinedMap.LayoutViewColumn, configuration => configuration.MapName = LayoutViewColumnMapName);
            moduleManager.ExtendMap(PredefinedMap.LayoutView)
            .Subscribe(_ => _.extenders.Add(_.targetInterface, typeof(IModelLayoutViewDesign)));

            var repositoryItems = EnumsNET.Enums.GetValues <PredefinedMap>().Where(map => map.IsRepositoryItem()).ToArray();

            moduleManager.Extend(repositoryItems);

            moduleManager.Extend(PredefinedMap.RichEditControl);

            moduleManager.ExtendMap(PredefinedMap.RichEditControl)
            .Subscribe(_ => _.extenders.Add(_.targetInterface, typeof(IModelRichEditEx)));
        }
コード例 #2
0
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     moduleManager.Extend(PredefinedMap.DashboardDesigner, configuration => {
         configuration.MapName = "DesignerSettings";
         configuration.TargetInterfaceTypes.Clear();
         configuration.TargetInterfaceTypes.Add(typeof(IModelDashboardModule));
     });
     moduleManager.Extend(PredefinedMap.DashboardViewer);
 }
コード例 #3
0
        private static void ExtendModel(ApplicationModulesManager moduleManager)
        {
            var excludeMaps = new[]
            { PredefinedMap.None, PredefinedMap.LayoutView, PredefinedMap.LayoutViewColumn, PredefinedMap.LabelControl };

            moduleManager.Extend(Enum.GetValues(typeof(PredefinedMap)).OfType <PredefinedMap>()
                                 .Where(map => !excludeMaps.Contains(map) && map.Platform() == Platform.Win));
            // if (!Debugger.IsAttached){
            moduleManager.Extend(Enum.GetValues(typeof(PredefinedMap)).OfType <PredefinedMap>().Where(map => map == PredefinedMap.ChartControl)
                                 .Where(map => !excludeMaps.Contains(map) && map.Platform() == Platform.Win));
            // }
        }
コード例 #4
0
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     moduleManager.ExtendMap(PredefinedMap.PivotGridControl)
     .SelectMany(_ => new[] { typeof(IModelPivotNetIncome), typeof(IModelPivotGridExtender), typeof(IModelPivotTopObject) }
                 .Select(extenderType => (_, _.targetInterface, extenderType))
                 .Concat(_.targetInterface.Assembly.GetTypes().Where(type => type.Name == $"IModel{PredefinedMap.RepositoryItemSpinEdit}")
                         .Select(type => (_, targetInterface: typeof(IModelPivotSpinEditRule), extenderType: type))))
     .Subscribe(_ => _._.extenders.Add(_.targetInterface, _.extenderType));
     moduleManager.Extend(PredefinedMap.PivotGridControl, configuration => configuration.MapName = PivotGridControlModelName);
     moduleManager.Extend(PredefinedMap.PivotGridField, configuration => configuration.MapName   = PivotGridFieldModelName);
     moduleManager.Extend(PredefinedMap.RepositoryItemSpinEdit, configuration => configuration.TargetInterfaceTypes.Add(typeof(IModelPivotSpinEditRule)));
 }
コード例 #5
0
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     moduleManager.Extend(PredefinedMap.DashboardDesigner, configuration => {
         configuration.MapName = "DesignerSettings";
         configuration.TargetInterfaceTypes.Clear();
         configuration.TargetInterfaceTypes.Add(typeof(IModelDashboardModule));
     });
     moduleManager.Extend(PredefinedMap.DashboardViewer);
     moduleManager.Extend(PredefinedMap.RichEditControl);
     moduleManager.ExtendMap(PredefinedMap.RichEditControl)
     .Subscribe(_ => _.extenders.Add(_.targetInterface, typeof(IModelRichEditEx)));
 }
コード例 #6
0
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     moduleManager.Connect()
     .Subscribe(this);
     moduleManager.Extend(PredefinedMap.GridView);
 }
コード例 #7
0
ファイル: WinModule.cs プロジェクト: xyyhqq/eXpand
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     moduleManager.Extend(PredefinedMap.RichEditControl);
     moduleManager.ExtendMap(PredefinedMap.RichEditControl)
     .Subscribe(_ => _.extenders.Add(_.targetInterface, typeof(IModelRichEditEx)));
 }
コード例 #8
0
ファイル: XpandChartWinModule.cs プロジェクト: xyyhqq/eXpand
        public override void Setup(ApplicationModulesManager moduleManager)
        {
            base.Setup(moduleManager);
            moduleManager.Extend(PredefinedMap.ChartControl, configuration => configuration.MapName = ChartControlMapName);

            var diagrams = Enums.GetMembers <PredefinedMap>().Where(member =>
                                                                    member.Name.StartsWith(PredefinedMap.ChartControl.ToString()) &&
                                                                    member.Value != PredefinedMap.ChartControl && member.Value != PredefinedMap.ChartControlDiagram).Select(member => member.Value).ToArray();

            moduleManager.Extend((map, configuration) => {
                configuration.MapName     = $"{map.ToString().Replace(PredefinedMap.ChartControl.ToString(), "Chart")}";
                configuration.DisplayName = $"{map.ToString().Replace(PredefinedMap.ChartControl.ToString(), "")}";
            }, diagrams);

            moduleManager.ExtendMap(PredefinedMap.ChartControl)
            .Subscribe(_ => _.extenders.Add(_.targetInterface, typeof(IModelOptionsChartEx)));
        }
コード例 #9
0
ファイル: WebModule.cs プロジェクト: Fringilla/DevExpress.XAF
        public override void Setup(ApplicationModulesManager moduleManager)
        {
            base.Setup(moduleManager);

            moduleManager.Extend(Enum.GetValues(typeof(PredefinedMap)).OfType <PredefinedMap>().Where(map => map != PredefinedMap.None && map.Platform() == Platform.Web));
            moduleManager.LookupCascade()
            .TakeUntilDisposed(this)
            .Subscribe();
        }
コード例 #10
0
        public override void Setup(ApplicationModulesManager moduleManager)
        {
            base.Setup(moduleManager);
            moduleManager.Extend(PredefinedMap.ASPxGridView, configuration => configuration.MapName       = ASPxGridViewMapName);
            moduleManager.Extend(PredefinedMap.GridViewDataColumn, configuration => configuration.MapName = GridViewColumnMapName);
            var propertyEditorMaps = new[] {
                PredefinedMap.ASPxComboBox, PredefinedMap.ASPxDateEdit, PredefinedMap.ASPxHyperLink,
                PredefinedMap.ASPxLookupDropDownEdit, PredefinedMap.ASPxLookupFindEdit,
                PredefinedMap.ASPxSpinEdit, PredefinedMap.ASPxTokenBox
            }.ToArray();

            moduleManager.Extend(propertyEditorMaps);
            moduleManager.Extend(PredefinedMap.ASPxPopupControl, configuration => configuration.MapName = CustomizeASPxPopupController.PopupControlMapName);
            moduleManager.ExtendMap(PredefinedMap.ASPxPopupControl)
            .Subscribe(_ => _.extenders.Add(_.targetInterface, typeof(IModelWebPopupControl)));
            moduleManager.Extend(PredefinedMap.ASPxComboBox, PredefinedMap.ASPxDateEdit, PredefinedMap.ASPxHyperLink,
                                 PredefinedMap.ASPxLookupDropDownEdit, PredefinedMap.ASPxLookupFindEdit, PredefinedMap.ASPxSpinEdit, PredefinedMap.ASPxTokenBox);
        }
コード例 #11
0
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     if (Application != null)
     {
         var winApplication = Application as WinApplication;
         winApplication?.HandleException();
         Application.LoggedOff += Application_LoggedOff;
         Application.Disposed  += Application_Disposed;
     }
     moduleManager.Extend(PredefinedMap.RichEditControl);
 }
コード例 #12
0
ファイル: WinModule.cs プロジェクト: ebozgeyik/eXpand
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     if (Application != null)
     {
         var winApplication = Application as WinApplication;
         winApplication?.HandleException();
         Application.LoggedOff += Application_LoggedOff;
         Application.Disposed  += Application_Disposed;
     }
     moduleManager.Extend(PredefinedMap.RichEditControl);
     moduleManager.ExtendMap(PredefinedMap.RichEditControl)
     .Subscribe(_ => _.extenders.Add(_.targetInterface, typeof(IModelRichEditEx)));
 }
コード例 #13
0
        public override void Setup(ApplicationModulesManager moduleManager)
        {
            base.Setup(moduleManager);


            if (!Debugger.IsAttached)
            {
                moduleManager.Extend(Enum.GetValues(typeof(PredefinedMap)).OfType <PredefinedMap>().Where(map => map != PredefinedMap.None && map.Platform() == Platform.Web));
            }
            moduleManager.LookupCascade().ToUnit()
            .Merge(moduleManager.ConnectMicrosoftCalendarService())
            .Merge(moduleManager.ConnectMicrosoftService())
            .Merge(moduleManager.ConnectMicrosoftTodoService())
            .Subscribe(this);
        }
コード例 #14
0
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     moduleManager.Extend(PredefinedMap.SchedulerControl);
     moduleManager.ExtendMap(PredefinedMap.SchedulerControl)
     .Subscribe(_ => {
         var propertyType = _.targetInterface.GetProperty(SchedulerControlService.PopupMenusMoelPropertyName)?.PropertyType;
         if (propertyType != null)
         {
             var targetInterface = propertyType.GetInterfaces()
                                   .First(type => type.IsGenericType && type.GetGenericTypeDefinition() == typeof(IModelList <>))
                                   .GenericTypeArguments.First();
             _.extenders.Add(targetInterface, typeof(IModelSchedulerPopupMenuItemEx));
         }
     });
 }
コード例 #15
0
 public static void Extend <TTargetInterface>(this ApplicationModulesManager modulesManager, Type extenderType)
     where TTargetInterface : IModelNode
 {
     modulesManager.Extend(new ModelMapperConfiguration(extenderType, typeof(TTargetInterface)));
 }
コード例 #16
0
 public static void Extend <TTargetInterface, TExtenderType>(this ApplicationModulesManager modulesManager) where TTargetInterface : IModelNode where TExtenderType : class
 {
     modulesManager.Extend(new ModelMapperConfiguration(typeof(TExtenderType), typeof(TTargetInterface)));
 }
コード例 #17
0
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     moduleManager.Extend(PredefinedMap.ASPxUploadControl);
 }
コード例 #18
0
        public override void Setup(ApplicationModulesManager moduleManager)
        {
            base.Setup(moduleManager);

            moduleManager.Extend(PredefinedMap.ASPxDashboard);
        }
コード例 #19
0
 public override void Setup(ApplicationModulesManager moduleManager)
 {
     base.Setup(moduleManager);
     moduleManager.Extend(PredefinedMap.TreeList, configuration => configuration.MapName       = TreeListMapName);
     moduleManager.Extend(PredefinedMap.TreeListColumn, configuration => configuration.MapName = TreeListColumnMapName);
 }