Exemplo n.º 1
0
 internal ComponentApplication(ComponentApplication componentApplication) : this(Interop.ComponentApplication.NewComponentApplication(ComponentApplication.getCPtr(componentApplication)), true)
 {
     if (NDalicPINVOKE.SWIGPendingException.Pending)
     {
         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
     }
 }
Exemplo n.º 2
0
        internal ComponentApplication Assign(ComponentApplication componentApplication)
        {
            ComponentApplication ret = new ComponentApplication(Interop.ComponentApplication.Assign(swigCPtr, ComponentApplication.getCPtr(componentApplication)), false);

            if (NDalicPINVOKE.SWIGPendingException.Pending)
            {
                throw NDalicPINVOKE.SWIGPendingException.Retrieve();
            }
            return(ret);
        }
Exemplo n.º 3
0
        public static ComponentApplication NewComponentApplication(string[] args, string stylesheet)
        {
            ComponentApplication ret = New(args, stylesheet);

            if (NDalicPINVOKE.SWIGPendingException.Pending)
            {
                throw NDalicPINVOKE.SWIGPendingException.Retrieve();
            }
            instance = ret;
            return(ret);
        }
Exemplo n.º 4
0
        /// <summary>
        /// Run Application.
        /// </summary>
        /// <param name="args">Arguments from commandline.</param>
        public void Run(string[] args)
        {
            TizenSynchronizationContext.Initialize();

            args[0]      = Tizen.Applications.Application.Current.ApplicationInfo.ExecutablePath;
            _application = ComponentApplication.NewComponentApplication(args, _stylesheet);

            _application.Initialized  += OnInitialized;
            _application.CreateNative += OnCreateNative;
            _application.Terminating  += OnTerminated;

            _application.MainLoop();
        }
Exemplo n.º 5
0
        public static ComponentApplication New(string[] args, string stylesheet)
        {
            int    argc    = args.Length;
            string argvStr = string.Join(" ", args);

            IntPtr widgetIntPtr = Interop.ComponentApplication.New(argc, argvStr, stylesheet);

            ComponentApplication ret = new ComponentApplication(widgetIntPtr, false);

            if (NDalicPINVOKE.SWIGPendingException.Pending)
            {
                throw NDalicPINVOKE.SWIGPendingException.Retrieve();
            }

            return(ret);
        }
Exemplo n.º 6
0
        public override IWindowInfo CreateWindowInfo()
        {
            ComponentApplication instance = ComponentApplication.Instance as ComponentApplication;

            if (instance)
            {
                instance.RegisterFrameComponent(this);
                if (instance.GetFrameComponentCount() == 1)
                {
                    Window = instance.GetWindow();
                }
                else
                {
                    Window = new Window();
                }
            }
            NUIWindowInfo = new NUIWindowInfo(Window);
            return(NUIWindowInfo);
        }
Exemplo n.º 7
0
        public override IWindowInfo CreateWindowInfo()
        {
            ComponentApplication instance = ComponentApplication.Instance as ComponentApplication;

            if (instance != null)
            {
                if (!defaultWindowSet)
                {
                    instance.GetWindow().WindowPositionSize = new Rectangle(0, 0, 1, 1);
                    instance.GetWindow().BackgroundColor    = new Color(0, 0, 0, 0);
                    instance.GetWindow().Hide();
                    defaultWindowSet = true;
                }

                Window = new Window();
                Window.Show();
            }
            NUIWindowInfo = new NUIWindowInfo(Window);
            return(NUIWindowInfo);
        }
Exemplo n.º 8
0
 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ComponentApplication obj)
 {
     return((obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr);
 }