Inheritance: IThemeManager
        public SingleDepthNodeRenderer(NavigatorView parentNavigatorView, INodeProxy nodeProxy, ThemeManager themeManager, string skinName)
            : base(parentNavigatorView, nodeProxy, themeManager, skinName)
        {

        }
Example #2
0
        public MainPage()
        {
            DebugLogger.Instance.LogMsg("Initialising Glyma...   Url: " + HtmlPage.Document.DocumentUri);
            InitializeComponent();
            SetupNetworkChange(); //logs if the network is going up/down
            Sidebar.Handler = SuperGraph;
            ZommingControl.Handler = SuperGraph;
            Breadcrumbs.Handler = SuperGraph;
            SuperGraph.Ref = this;
            if (!App.IsDesignTime)
            {
                Loader.Visibility = Visibility.Visible;
                Breadcrumbs.BreadcrumbChanged += OnBreadcrumbChanged;
                Breadcrumbs.BreadcrumbClicked += OnBreadcrumbClicked;
                SuperGraph.DataContext = new SuperGraphProperties
                {
                    NodeTextWidth = GlymaParameters.NodeTextWidth,
                    NodeImageWidth = GlymaParameters.NodeImageWidth,
                    NodeImageHeight = GlymaParameters.NodeImageHeight
                };

                SoapEndPointFactory soapEndPointFactory = new SoapEndPointFactory(new Uri(App.Params.TransactionalMappingToolSvcUrl));
                var soapMapManager = new SoapProxy.SoapMapManager(soapEndPointFactory);

                _mapManager = soapMapManager;
                _mapManager.InitialiseMapManagerCompleted += OnInitialiseMapManagerCompleted;
                
                _mapManager.MapManagerActivityStatusUpdated += OnMapManagerActivityStatusUpdated;
                IoCContainer.GetInjectionInstance().RegisterComponent<Proxy.IMapManager, SoapProxy.SoapMapManager>(soapMapManager);

                var binding = new System.ServiceModel.BasicHttpBinding();
                binding.Security.Mode = System.ServiceModel.BasicHttpSecurityMode.TransportCredentialOnly;
                binding.MaxReceivedMessageSize = 2147483647;

                var utilityServiceAddress = new System.ServiceModel.EndpointAddress(new Uri(App.Params.GlymaUtilitySvcUrl));
                var utilityManagerServiceClient = new UtilityProxy.Service.UtilityServiceManagerClient(binding, utilityServiceAddress);
                var exportServiceManager = new UtilityProxy.ExportServiceManager(utilityManagerServiceClient);
                IoCContainer.GetInjectionInstance().RegisterComponent<UtilityProxy.IExportServiceManager, UtilityProxy.ExportServiceManager>(exportServiceManager);
                exportServiceManager.IsExportingAvailableCompleted.RegisterEvent(IsExportingAvailableCompleted);

                _themeManager = new ThemeManager();

                SuperGraph.NodeClicked += NodeClicked;
                SuperGraph.FilesDropped += FilesDropped;

                var jsBridge = new JavaScriptBridge(SuperGraph);
                HtmlPage.RegisterScriptableObject("glymaMapCanvas", jsBridge);

                exportServiceManager.IsExportingAvailableAsync();
            }
        }