This repository has been archived by the owner on Sep 11, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
seperate jsb assemblies from assemblies of project with asmdef
- Loading branch information
Showing
15 changed files
with
311 additions
and
182 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,28 @@ | ||
using System; | ||
using System.IO; | ||
using System.Collections.Generic; | ||
using System.Reflection; | ||
|
||
namespace QuickJS.Binding | ||
{ | ||
public interface IBindingUtils | ||
{ | ||
string ReplacePathVars(string value); | ||
|
||
bool IsExplicitEditorType(Type type); | ||
} | ||
|
||
public class DefaultBindingUtils : IBindingUtils | ||
{ | ||
public string ReplacePathVars(string value) | ||
{ | ||
#if JSB_UNITYLESS | ||
value = value.Replace("${platform}", "unityless"); | ||
return value; | ||
#else | ||
return Unity.UnityHelper.ReplacePathVars(value); | ||
#endif | ||
} | ||
|
||
public bool IsExplicitEditorType(Type type) | ||
{ | ||
#if JSB_UNITYLESS | ||
return false; | ||
#else | ||
return Unity.UnityHelper.IsExplicitEditorType(type); | ||
#endif | ||
} | ||
} | ||
using System; | ||
using System.IO; | ||
using System.Collections.Generic; | ||
using System.Reflection; | ||
|
||
namespace QuickJS.Binding | ||
{ | ||
public interface IBindingUtils | ||
{ | ||
string ReplacePathVars(string value); | ||
|
||
bool IsExplicitEditorType(Type type); | ||
} | ||
|
||
public class DefaultBindingUtils : IBindingUtils | ||
{ | ||
public string ReplacePathVars(string value) | ||
{ | ||
value = value.Replace("${platform}", "unityless"); | ||
return value; | ||
} | ||
|
||
public bool IsExplicitEditorType(Type type) | ||
{ | ||
return false; | ||
} | ||
} | ||
} |
17 changes: 17 additions & 0 deletions
17
Assets/jsb/Source/Binding/Editor/jsb.editor.binding.asmdef
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"name": "jsb.editor.binding", | ||
"references": [ | ||
"GUID:118b4ca3a1852354bac065cf952c1e85" | ||
], | ||
"includePlatforms": [ | ||
"Editor" | ||
], | ||
"excludePlatforms": [], | ||
"allowUnsafeCode": true, | ||
"overrideReferences": false, | ||
"precompiledReferences": [], | ||
"autoReferenced": true, | ||
"defineConstraints": [], | ||
"versionDefines": [], | ||
"noEngineReferences": false | ||
} |
7 changes: 7 additions & 0 deletions
7
Assets/jsb/Source/Binding/Editor/jsb.editor.binding.asmdef.meta
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
using System; | ||
using System.IO; | ||
using System.Collections.Generic; | ||
using System.Reflection; | ||
|
||
namespace QuickJS.Unity | ||
{ | ||
public class UnityBindingUtils : Binding.IBindingUtils | ||
{ | ||
public string ReplacePathVars(string value) | ||
{ | ||
return Unity.UnityHelper.ReplacePathVars(value); | ||
} | ||
|
||
public bool IsExplicitEditorType(Type type) | ||
{ | ||
return Unity.UnityHelper.IsExplicitEditorType(type); | ||
} | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.