\r
<ItemGroup>\r
<PackageReference Include="System.Reflection.TypeExtensions" Version="4.3.0" PrivateAssets="All" />\r
- <PackageReference Include="Tizen.Applications.Common" Version="1.5.8" />\r
- <PackageReference Include="Tizen.System.SystemSettings" Version="1.0.4" PrivateAssets="All"/>\r
+ <PackageReference Include="Tizen.Applications.Common" Version="1.5.10" />\r
+ <PackageReference Include="Tizen.System.SystemSettings" Version="1.0.4" PrivateAssets="All" />\r
</ItemGroup>\r
<Target Name="ChangeAliasesOfStrongNameAssemblies" BeforeTargets="FindReferenceAssembliesForReferences;ResolveReferences">\r
<ItemGroup>\r
return ret;
}
+
+ public static Application NewApplication(string[] args, string stylesheet, Application.WindowMode windowMode)
+ {
+ NUILog.Debug(" NewApplication(string[] args, string stylesheet, Application.WindowMode windowMode) is called! ");
+
+ Application ret = New(args, stylesheet, (Application.WindowMode)windowMode);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+
+ // we've got an application now connect the signals
+ ret.SetupDelegates();
+ // set the singleton
+ _instance = ret;
+ return _instance;
+ }
+
//Removed from v0.2.33
/*public bool AddIdle(System.Delegate func)
{
return ret;
}
+ public static Application New(string[] args, string stylesheet, Application.WindowMode windowMode)
+ {
+ NUILog.Debug("New(string[] args) is called!");
+ int argc = args.Length;
+ string argvStr = "";
+ for (int index = 0; index < args.Length; index++)
+ {
+ if(index == (args.Length - 1))
+ {
+ argvStr = argvStr + args[index];
+ }
+ else
+ {
+ argvStr = argvStr + args[index] + " ";
+ }
+ }
+
+ Application ret = new Application(NDalicPINVOKE.Application_New__MANUAL_4(argc, argvStr, stylesheet, (int)windowMode), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
public static Application New(int argc, string stylesheet, Application.WindowMode windowMode, Rectangle positionSize)
{
Application ret = new Application(NDalicPINVOKE.Application_New__SWIG_4(argc, stylesheet, (int)windowMode, Rectangle.getCPtr(positionSize)), true);
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_Application_New__SWIG_3")]
public static extern global::System.IntPtr Application_New__SWIG_3(int jarg1, string jarg3, int jarg4);
+ [global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_Application_New__MANUAL_4")]
+ public static extern global::System.IntPtr Application_New__MANUAL_4(int jarg1, string jarg2, string jarg3, int jarg4);
+
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_new_Application__SWIG_0")]
public static extern global::System.IntPtr new_Application__SWIG_0();
[global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_Dali_Application_New__SWIG_4")]
public static extern global::System.IntPtr Application_New__SWIG_4(int jarg1, string jarg3, int jarg4, global::System.Runtime.InteropServices.HandleRef jarg5);
-
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_TimerSignalType_Empty")]
public static extern bool TimerSignalType_Empty(global::System.Runtime.InteropServices.HandleRef jarg1);
/// Application instance to connect event.
/// </summary>
protected Application _application;
+ private string _stylesheet = "";
+ private NUIApplication.WindowMode _windowMode = NUIApplication.WindowMode.Opaque;
/// <summary>
/// Dictionary to contain each type of event callback.
/// </summary>
public NUICoreBackend()
{
- _application = Application.NewApplication();
}
/// <summary>
/// </summary>
public NUICoreBackend(string stylesheet)
{
- _application = Application.NewApplication(stylesheet);
+ _stylesheet = stylesheet;
}
/// <summary>
/// </summary>
public NUICoreBackend(string stylesheet, NUIApplication.WindowMode windowMode)
{
- _application = Application.NewApplication(stylesheet, (Application.WindowMode)windowMode );
+ _stylesheet = stylesheet;
+ _windowMode = windowMode;
}
/// <summary>
/// </summary>
public void Dispose()
{
- _application.Dispose();
+ if(_application != null)
+ {
+ _application.Dispose();
+ }
}
/// <summary>
/// </summary>
public void Exit()
{
- _application.Quit();
+ if(_application != null)
+ {
+ _application.Quit();
+ }
}
/// <summary>
public void Run(string[] args)
{
TizenSynchronizationContext.Initialize();
+
+ args[0] = Tizen.Applications.Application.Current.ApplicationInfo.ExecutablePath;
+ if (args.Length == 1)
+ {
+ _application = Application.NewApplication();
+ }
+ else if (args.Length > 1)
+ {
+ _application = Application.NewApplication(args, _stylesheet, (Application.WindowMode)_windowMode);
+ }
+
_application.BatteryLow += OnBatteryLow;
_application.LanguageChanged += OnLanguageChanged;
_application.MemoryLow += OnMemoryLow;