コード例 #1
0
        public void DefaultFrameBrokerSendLaunchRequest()
        {
            tlog.Debug(tag, $"DefaultFrameBrokerSendLaunchRequest START");

            var testingTarget = new DefaultFrameBroker(Window.Instance);

            Assert.IsNotNull(testingTarget, "Can't create success object CustomView");
            Assert.IsInstanceOf <DefaultFrameBroker>(testingTarget, "Should be an instance of DefaultFrameBroker type.");

            try
            {
                Tizen.Applications.AppControl appControl = new Tizen.Applications.AppControl();
                appControl.Operation     = Tizen.Applications.AppControlOperations.Call;
                appControl.ApplicationId = MyAppId;
                testingTarget.SendLaunchRequest(appControl, true);
            }
            catch (Exception e)
            {
                tlog.Debug(tag, e.Message.ToString());
                Assert.Fail("Caught Exception : Failed!");
            }

            testingTarget.Dispose();

            tlog.Debug(tag, $"DefaultFrameBrokerSendLaunchRequest END (OK)");
        }
コード例 #2
0
        public void OpenUriAction(Uri uri)
        {
            if (uri == null || uri.AbsoluteUri == null)
            {
                throw new ArgumentNullException(nameof(uri));
            }
            TAppControl tAppControl = new TAppControl()
            {
                Operation = "%", Uri = uri.AbsoluteUri
            };
            var matchedApplications = TAppControl.GetMatchedApplicationIds(tAppControl);

            if (matchedApplications.Any())
            {
                TAppControl.SendLaunchRequest(tAppControl);
                return;
            }
            throw new PlatformNotSupportedException();
        }
コード例 #3
0
ファイル: TSNUIFrameComponent.cs プロジェクト: wonrst/TizenFX
        public void NUIFrameComponentOnStart()
        {
            tlog.Debug(tag, $"NUIFrameComponentOnStart START");

            var testingTarget = new MyNUIFrameComponent();

            Assert.IsNotNull(testingTarget, "Should be not null.");
            Assert.IsInstanceOf <NUIFrameComponent>(testingTarget, "Should be an instance of NUIFrameComponent type.");

            try
            {
                Tizen.Applications.AppControl appControl = new Tizen.Applications.AppControl(true);
                testingTarget.MyOnStart(appControl, false);
            }
            catch (Exception e)
            {
                tlog.Debug(tag, e.Message.ToString());
                Assert.Fail("Caught Exception: Failed!");
            }

            tlog.Debug(tag, $"NUIFrameComponentOnStart END (OK)");
        }
コード例 #4
0
ファイル: TSNUIFrameComponent.cs プロジェクト: wonrst/TizenFX
 public void MyOnStart(Tizen.Applications.AppControl appControl, bool restarted)
 {
     base.OnStart(appControl, restarted);
 }