diff --git a/popcorn/Assets/Examples.meta b/popcorn/Assets/Examples.meta new file mode 100644 index 00000000..a7ef647d --- /dev/null +++ b/popcorn/Assets/Examples.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8ae0b06cb10ac46d8bb8f5bc0261761c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scenes.meta b/popcorn/Assets/Examples/Scenes.meta new file mode 100644 index 00000000..eafc5d68 --- /dev/null +++ b/popcorn/Assets/Examples/Scenes.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 17e774d428c22429081ed67105885578 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scenes/DemoScene.unity b/popcorn/Assets/Examples/Scenes/DemoScene.unity new file mode 100644 index 00000000..051c9e05 --- /dev/null +++ b/popcorn/Assets/Examples/Scenes/DemoScene.unity @@ -0,0 +1,2570 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!29 &1 +OcclusionCullingSettings: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_OcclusionBakeSettings: + smallestOccluder: 5 + smallestHole: 0.25 + backfaceThreshold: 100 + m_SceneGUID: 00000000000000000000000000000000 + m_OcclusionCullingData: {fileID: 0} +--- !u!104 &2 +RenderSettings: + m_ObjectHideFlags: 0 + serializedVersion: 9 + m_Fog: 0 + m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1} + m_FogMode: 3 + m_FogDensity: 0.01 + m_LinearFogStart: 0 + m_LinearFogEnd: 300 + m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1} + m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1} + m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1} + m_AmbientIntensity: 1 + m_AmbientMode: 0 + m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1} + m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0} + m_HaloStrength: 0.5 + m_FlareStrength: 1 + m_FlareFadeSpeed: 3 + m_HaloTexture: {fileID: 0} + m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} + m_DefaultReflectionMode: 0 + m_DefaultReflectionResolution: 128 + m_ReflectionBounces: 1 + m_ReflectionIntensity: 1 + m_CustomReflection: {fileID: 0} + m_Sun: {fileID: 0} + m_IndirectSpecularColor: {r: 0.44657815, g: 0.49641192, b: 0.57481617, a: 1} + m_UseRadianceAmbientProbe: 0 +--- !u!157 &3 +LightmapSettings: + m_ObjectHideFlags: 0 + serializedVersion: 11 + m_GIWorkflowMode: 0 + m_GISettings: + serializedVersion: 2 + m_BounceScale: 1 + m_IndirectOutputScale: 1 + m_AlbedoBoost: 1 + m_EnvironmentLightingMode: 0 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 1 + m_LightmapEditorSettings: + serializedVersion: 12 + m_Resolution: 2 + m_BakeResolution: 40 + m_AtlasSize: 1024 + m_AO: 0 + m_AOMaxDistance: 1 + m_CompAOExponent: 1 + m_CompAOExponentDirect: 0 + m_ExtractAmbientOcclusion: 0 + m_Padding: 2 + m_LightmapParameters: {fileID: 0} + m_LightmapsBakeMode: 1 + m_TextureCompression: 1 + m_FinalGather: 0 + m_FinalGatherFiltering: 1 + m_FinalGatherRayCount: 256 + m_ReflectionCompression: 2 + m_MixedBakeMode: 2 + m_BakeBackend: 1 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 500 + m_PVRBounces: 2 + m_PVREnvironmentSampleCount: 500 + m_PVREnvironmentReferencePointCount: 2048 + m_PVRFilteringMode: 2 + m_PVRDenoiserTypeDirect: 0 + m_PVRDenoiserTypeIndirect: 0 + m_PVRDenoiserTypeAO: 0 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVREnvironmentMIS: 0 + m_PVRCulling: 1 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 + m_ExportTrainingData: 0 + m_TrainingDataDestination: TrainingData + m_LightProbeSampleCountMultiplier: 4 + m_LightingDataAsset: {fileID: 0} + m_UseShadowmask: 1 +--- !u!196 &4 +NavMeshSettings: + serializedVersion: 2 + m_ObjectHideFlags: 0 + m_BuildSettings: + serializedVersion: 2 + agentTypeID: 0 + agentRadius: 0.5 + agentHeight: 2 + agentSlope: 45 + agentClimb: 0.4 + ledgeDropHeight: 0 + maxJumpAcrossDistance: 0 + minRegionArea: 2 + manualCellSize: 0 + cellSize: 0.16666667 + manualTileSize: 0 + tileSize: 256 + accuratePlacement: 0 + debug: + m_Flags: 0 + m_NavMeshData: {fileID: 0} +--- !u!1 &109539175 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 109539176} + - component: {fileID: 109539178} + - component: {fileID: 109539177} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &109539176 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 109539175} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1872018357} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &109539177 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 109539175} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 50 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 0 + m_MaxSize: 50 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: RewardVideo +--- !u!222 &109539178 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 109539175} + m_CullTransparentMesh: 0 +--- !u!224 &124328370 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + m_PrefabInstance: {fileID: 113652593457284252} + m_PrefabAsset: {fileID: 0} +--- !u!1001 &192501906 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 446936925} + m_Modifications: + - target: {fileID: 5466890875353275757, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_Name + value: MoreGameButton + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_RootOrder + value: 8 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_AnchorMax.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_AnchorMax.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_AnchorMin.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_AnchorMin.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_SizeDelta.x + value: 154.5 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_SizeDelta.y + value: 132 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_AnchoredPosition.x + value: 364 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_AnchoredPosition.y + value: 843 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 74a7a78e879394178a1941a9d076df74, type: 3} +--- !u!224 &192501907 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5466890875353275758, guid: 74a7a78e879394178a1941a9d076df74, + type: 3} + m_PrefabInstance: {fileID: 192501906} + m_PrefabAsset: {fileID: 0} +--- !u!1 &446936924 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 446936925} + - component: {fileID: 446936927} + - component: {fileID: 446936926} + m_Layer: 5 + m_Name: Panel + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &446936925 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 446936924} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 993180820} + - {fileID: 1133062232} + - {fileID: 966044319} + - {fileID: 1469376979} + - {fileID: 1872018357} + - {fileID: 1981571842} + - {fileID: 1543566406} + - {fileID: 1849251594} + - {fileID: 192501907} + - {fileID: 124328370} + - {fileID: 1178359119} + m_Father: {fileID: 613713352} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &446936926 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 446936924} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 91c7aa3bcdee0466f9efbf40c929f2e0, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &446936927 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 446936924} + m_CullTransparentMesh: 0 +--- !u!1001 &547609663 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_RootOrder + value: 5 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393010, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2198125272684393013, guid: 31f1c1f5853254b37a7bc3aa95e24977, + type: 3} + propertyPath: m_Name + value: JoypacIAP + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 31f1c1f5853254b37a7bc3aa95e24977, type: 3} +--- !u!1 &556970809 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 556970812} + - component: {fileID: 556970811} + - component: {fileID: 556970810} + m_Layer: 0 + m_Name: EventSystem + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &556970810 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 556970809} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4f231c4fb786f3946a6b90b886c48677, type: 3} + m_Name: + m_EditorClassIdentifier: + m_HorizontalAxis: Horizontal + m_VerticalAxis: Vertical + m_SubmitButton: Submit + m_CancelButton: Cancel + m_InputActionsPerSecond: 10 + m_RepeatDelay: 0.5 + m_ForceModuleActive: 0 +--- !u!114 &556970811 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 556970809} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 76c392e42b5098c458856cdf6ecaaaa1, type: 3} + m_Name: + m_EditorClassIdentifier: + m_FirstSelected: {fileID: 0} + m_sendNavigationEvents: 1 + m_DragThreshold: 10 +--- !u!4 &556970812 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 556970809} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &613713348 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 613713352} + - component: {fileID: 613713351} + - component: {fileID: 613713350} + - component: {fileID: 613713349} + m_Layer: 5 + m_Name: Canvas + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &613713349 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 613713348} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &613713350 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 613713348} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, type: 3} + m_Name: + m_EditorClassIdentifier: + m_UiScaleMode: 0 + m_ReferencePixelsPerUnit: 100 + m_ScaleFactor: 1 + m_ReferenceResolution: {x: 800, y: 600} + m_ScreenMatchMode: 0 + m_MatchWidthOrHeight: 0 + m_PhysicalUnit: 3 + m_FallbackScreenDPI: 96 + m_DefaultSpriteDPI: 96 + m_DynamicPixelsPerUnit: 1 +--- !u!223 &613713351 +Canvas: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 613713348} + m_Enabled: 1 + serializedVersion: 3 + m_RenderMode: 1 + m_Camera: {fileID: 1478127799} + m_PlaneDistance: 100 + m_PixelPerfect: 0 + m_ReceivesEvents: 1 + m_OverrideSorting: 0 + m_OverridePixelPerfect: 0 + m_SortingBucketNormalizedSize: 0 + m_AdditionalShaderChannelsFlag: 0 + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_TargetDisplay: 0 +--- !u!224 &613713352 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 613713348} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 446936925} + m_Father: {fileID: 0} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0, y: 0} +--- !u!1 &966044318 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 966044319} + - component: {fileID: 966044322} + - component: {fileID: 966044321} + - component: {fileID: 966044320} + - component: {fileID: 966044323} + m_Layer: 5 + m_Name: InterIV1 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &966044319 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 966044318} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 968492217} + m_Father: {fileID: 446936925} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -251, y: 430} + m_SizeDelta: {x: 416.25, y: 119.52} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &966044320 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 966044318} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 966044321} + m_OnClick: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &966044321 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 966044318} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 76313e85d379943bc9059b2dc49a0817, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &966044322 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 966044318} + m_CullTransparentMesh: 0 +--- !u!114 &966044323 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 966044318} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: a2947b0ff488544b48c0a4a3ebfc2939, type: 3} + m_Name: + m_EditorClassIdentifier: + iVNumber: 0 +--- !u!1 &968492216 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 968492217} + - component: {fileID: 968492219} + - component: {fileID: 968492218} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &968492217 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 968492216} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 966044319} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &968492218 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 968492216} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 50 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 0 + m_MaxSize: 50 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: InterIV1 +--- !u!222 &968492219 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 968492216} + m_CullTransparentMesh: 0 +--- !u!1 &980866581 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 980866582} + - component: {fileID: 980866584} + - component: {fileID: 980866583} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &980866582 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 980866581} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1981571842} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &980866583 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 980866581} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 37 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 0 + m_MaxSize: 50 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: ShowSettingPopView +--- !u!222 &980866584 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 980866581} + m_CullTransparentMesh: 0 +--- !u!1 &993180819 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 993180820} + - component: {fileID: 993180823} + - component: {fileID: 993180822} + - component: {fileID: 993180821} + - component: {fileID: 993180824} + m_Layer: 5 + m_Name: Banner + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &993180820 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 993180819} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1418699422} + m_Father: {fileID: 446936925} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -254, y: 596} + m_SizeDelta: {x: 416.25, y: 119.52} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &993180821 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 993180819} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 993180822} + m_OnClick: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &993180822 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 993180819} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 76313e85d379943bc9059b2dc49a0817, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &993180823 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 993180819} + m_CullTransparentMesh: 0 +--- !u!114 &993180824 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 993180819} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 70e15a32390af4068935f850828f3c2d, type: 3} + m_Name: + m_EditorClassIdentifier: + text: {fileID: 1418699423} +--- !u!1 &1133062231 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1133062232} + - component: {fileID: 1133062235} + - component: {fileID: 1133062234} + - component: {fileID: 1133062233} + - component: {fileID: 1133062236} + m_Layer: 5 + m_Name: Native + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1133062232 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1133062231} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1998276733} + m_Father: {fileID: 446936925} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 243, y: 598} + m_SizeDelta: {x: 416.25, y: 119.52} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1133062233 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1133062231} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1133062234} + m_OnClick: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &1133062234 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1133062231} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 76313e85d379943bc9059b2dc49a0817, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1133062235 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1133062231} + m_CullTransparentMesh: 0 +--- !u!114 &1133062236 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1133062231} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d93a36bad8e9d43f288e5392cf291086, type: 3} + m_Name: + m_EditorClassIdentifier: + text: {fileID: 1998276734} + nativeAd: {fileID: 1178359122} +--- !u!1 &1178359118 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1178359119} + - component: {fileID: 1178359121} + - component: {fileID: 1178359120} + - component: {fileID: 1178359122} + m_Layer: 5 + m_Name: NativeAd + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1178359119 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1178359118} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 446936925} + m_RootOrder: 10 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -308} + m_SizeDelta: {x: 900, y: 700} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1178359120 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1178359118} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0, g: 0, b: 0, a: 0.0627451} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1178359121 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1178359118} + m_CullTransparentMesh: 0 +--- !u!114 &1178359122 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1178359118} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 882400d50cdba4cc09b32263b0c2b36e, type: 3} + m_Name: + m_EditorClassIdentifier: + uiCamera: {fileID: 1478127799} +--- !u!1 &1287966332 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1287966333} + - component: {fileID: 1287966335} + - component: {fileID: 1287966334} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1287966333 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1287966332} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1469376979} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1287966334 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1287966332} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 50 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 0 + m_MaxSize: 50 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: InterIV2 +--- !u!222 &1287966335 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1287966332} + m_CullTransparentMesh: 0 +--- !u!1 &1418699421 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1418699422} + - component: {fileID: 1418699424} + - component: {fileID: 1418699423} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1418699422 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1418699421} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 993180820} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1418699423 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1418699421} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 50 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 0 + m_MaxSize: 50 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Banner +--- !u!222 &1418699424 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1418699421} + m_CullTransparentMesh: 0 +--- !u!1 &1469376978 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1469376979} + - component: {fileID: 1469376982} + - component: {fileID: 1469376981} + - component: {fileID: 1469376980} + - component: {fileID: 1469376983} + m_Layer: 5 + m_Name: InterIV2 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1469376979 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1469376978} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1287966333} + m_Father: {fileID: 446936925} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 245, y: 429} + m_SizeDelta: {x: 416.25, y: 119.52} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1469376980 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1469376978} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1469376981} + m_OnClick: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &1469376981 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1469376978} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 76313e85d379943bc9059b2dc49a0817, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1469376982 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1469376978} + m_CullTransparentMesh: 0 +--- !u!114 &1469376983 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1469376978} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: a2947b0ff488544b48c0a4a3ebfc2939, type: 3} + m_Name: + m_EditorClassIdentifier: + iVNumber: 1 +--- !u!1 &1478127797 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1478127800} + - component: {fileID: 1478127799} + - component: {fileID: 1478127798} + m_Layer: 0 + m_Name: UICamera + m_TagString: MainCamera + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!81 &1478127798 +AudioListener: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1478127797} + m_Enabled: 1 +--- !u!20 &1478127799 +Camera: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1478127797} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0} + m_projectionMatrixMode: 1 + m_GateFitMode: 2 + m_FOVAxisMode: 0 + m_SensorSize: {x: 36, y: 24} + m_LensShift: {x: 0, y: 0} + m_FocalLength: 50 + m_NormalizedViewPortRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 1 + height: 1 + near clip plane: 0.3 + far clip plane: 1000 + field of view: 60 + orthographic: 1 + orthographic size: 5 + m_Depth: -1 + m_CullingMask: + serializedVersion: 2 + m_Bits: 32 + m_RenderingPath: -1 + m_TargetTexture: {fileID: 0} + m_TargetDisplay: 0 + m_TargetEye: 3 + m_HDR: 1 + m_AllowMSAA: 1 + m_AllowDynamicResolution: 0 + m_ForceIntoRT: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 +--- !u!4 &1478127800 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1478127797} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 1, y: 1, z: 1} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!224 &1543566406 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + m_PrefabInstance: {fileID: 1127298910029624011} + m_PrefabAsset: {fileID: 0} +--- !u!1 &1772972947 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1772972949} + - component: {fileID: 1772972948} + m_Layer: 0 + m_Name: Directional Light + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!108 &1772972948 +Light: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1772972947} + m_Enabled: 1 + serializedVersion: 10 + m_Type: 1 + m_Shape: 0 + m_Color: {r: 1, g: 0.95686275, b: 0.8392157, a: 1} + m_Intensity: 1 + m_Range: 10 + m_SpotAngle: 30 + m_InnerSpotAngle: 21.802082 + m_CookieSize: 10 + m_Shadows: + m_Type: 2 + m_Resolution: -1 + m_CustomResolution: -1 + m_Strength: 1 + m_Bias: 0.05 + m_NormalBias: 0.4 + m_NearPlane: 0.2 + m_CullingMatrixOverride: + e00: 1 + e01: 0 + e02: 0 + e03: 0 + e10: 0 + e11: 1 + e12: 0 + e13: 0 + e20: 0 + e21: 0 + e22: 1 + e23: 0 + e30: 0 + e31: 0 + e32: 0 + e33: 1 + m_UseCullingMatrixOverride: 0 + m_Cookie: {fileID: 0} + m_DrawHalo: 0 + m_Flare: {fileID: 0} + m_RenderMode: 0 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingLayerMask: 1 + m_Lightmapping: 4 + m_LightShadowCasterMode: 0 + m_AreaSize: {x: 1, y: 1} + m_BounceIntensity: 1 + m_ColorTemperature: 6570 + m_UseColorTemperature: 0 + m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0} + m_UseBoundingSphereOverride: 0 + m_ShadowRadius: 0 + m_ShadowAngle: 0 +--- !u!4 &1772972949 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1772972947} + m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261} + m_LocalPosition: {x: 0, y: 3, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0} +--- !u!1 &1849251593 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1849251594} + - component: {fileID: 1849251597} + - component: {fileID: 1849251596} + - component: {fileID: 1849251599} + - component: {fileID: 1849251598} + - component: {fileID: 1849251595} + m_Layer: 5 + m_Name: RemoveAd + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1849251594 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1849251593} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 446936925} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 186, y: 843} + m_SizeDelta: {x: 134.4, y: 134.4} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1849251595 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1849251593} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 9f4ca9ffa409f4848bcb57a7f45c7bc6, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!114 &1849251596 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1849251593} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 976be38b9c2df456eb2181d33ac4d8de, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1849251597 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1849251593} + m_CullTransparentMesh: 0 +--- !u!114 &1849251598 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1849251593} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 36a5f511b0d8142cba0aeb92d0b264c9, type: 3} + m_Name: + m_EditorClassIdentifier: + productId: homealone.removeads + buttonType: 0 + consumePurchase: 0 + onPurchaseComplete: + m_PersistentCalls: + m_Calls: [] + onPurchaseFailed: + m_PersistentCalls: + m_Calls: [] + titleText: {fileID: 0} + descriptionText: {fileID: 0} + priceText: {fileID: 0} +--- !u!114 &1849251599 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1849251593} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1849251596} + m_OnClick: + m_PersistentCalls: + m_Calls: [] +--- !u!1 &1872018356 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1872018357} + - component: {fileID: 1872018360} + - component: {fileID: 1872018359} + - component: {fileID: 1872018358} + - component: {fileID: 1872018361} + m_Layer: 5 + m_Name: RewardVideo + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1872018357 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1872018356} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 109539176} + m_Father: {fileID: 446936925} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -254, y: 268} + m_SizeDelta: {x: 416.25, y: 119.52} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1872018358 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1872018356} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1872018359} + m_OnClick: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &1872018359 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1872018356} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 76313e85d379943bc9059b2dc49a0817, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1872018360 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1872018356} + m_CullTransparentMesh: 0 +--- !u!114 &1872018361 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1872018356} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 90eba0ed596b44b86976d3ade08162d0, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!1 &1981571841 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1981571842} + - component: {fileID: 1981571846} + - component: {fileID: 1981571845} + - component: {fileID: 1981571844} + - component: {fileID: 1981571843} + m_Layer: 5 + m_Name: SettingPopViewButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1981571842 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1981571841} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 980866582} + m_Father: {fileID: 446936925} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 244, y: 268} + m_SizeDelta: {x: 416.25, y: 119.52} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1981571843 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1981571841} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 37e4f36d79aae43168d20938963a0b80, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!114 &1981571844 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1981571841} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1981571845} + m_OnClick: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &1981571845 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1981571841} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 76313e85d379943bc9059b2dc49a0817, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1981571846 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1981571841} + m_CullTransparentMesh: 0 +--- !u!1 &1998276732 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1998276733} + - component: {fileID: 1998276735} + - component: {fileID: 1998276734} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1998276733 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1998276732} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1133062232} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1998276734 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1998276732} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 50 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 0 + m_MaxSize: 50 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Native +--- !u!222 &1998276735 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1998276732} + m_CullTransparentMesh: 0 +--- !u!1001 &113652593457284252 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 446936925} + m_Modifications: + - target: {fileID: 113652593439005997, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_Name + value: PrivacyButton + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_RootOrder + value: 9 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_AnchorMax.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_AnchorMax.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_AnchorMin.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_AnchorMin.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_SizeDelta.x + value: 433 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_SizeDelta.y + value: 68 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_AnchoredPosition.x + value: -313 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_AnchoredPosition.y + value: 910 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 113652593439005998, guid: 9f68deb7bee674cce9d599804276a910, + type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 9f68deb7bee674cce9d599804276a910, type: 3} +--- !u!1001 &1127298910029624011 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 446936925} + m_Modifications: + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_RootOrder + value: 6 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_AnchorMax.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_AnchorMax.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_AnchorMin.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_AnchorMin.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_SizeDelta.x + value: 153 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_SizeDelta.y + value: 149 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalRotation.x + value: -0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalRotation.y + value: -0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalRotation.z + value: -0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_AnchoredPosition.y + value: 848 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811149, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1127298908888811150, guid: 2da03b9f5561d4108bd55d4984c47f31, + type: 3} + propertyPath: m_Name + value: FeedBackButton + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 2da03b9f5561d4108bd55d4984c47f31, type: 3} +--- !u!1001 &2105953404851886359 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_RootOrder + value: 4 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639821, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2105953405643639822, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, + type: 3} + propertyPath: m_Name + value: JoypacManager + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 9be0e7dcab12d4e9f8878dd9e5ccd2eb, type: 3} diff --git a/popcorn/Assets/Examples/Scenes/DemoScene.unity.meta b/popcorn/Assets/Examples/Scenes/DemoScene.unity.meta new file mode 100644 index 00000000..cc583d02 --- /dev/null +++ b/popcorn/Assets/Examples/Scenes/DemoScene.unity.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 116756f4486764b9585fa0e684c1e954 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scripts.meta b/popcorn/Assets/Examples/Scripts.meta new file mode 100644 index 00000000..9e9a4c11 --- /dev/null +++ b/popcorn/Assets/Examples/Scripts.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6ce5a29754994495287804d888b9d4a3 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scripts/BannerButton.cs b/popcorn/Assets/Examples/Scripts/BannerButton.cs new file mode 100644 index 00000000..c5e018f0 --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/BannerButton.cs @@ -0,0 +1,33 @@ + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using Joypac; +using UnityEngine.UI; +public class BannerButton : JPButton +{ + bool show = false; + [SerializeField] + private Text text = default; + public override void Start() + { + base.Start(); + text.text = "Banner"; + } + public override void OnClick() + { + if(show == false) + { + JoypacAdManager.Instance.ShowBanner(); + text.text = "HideBanner"; + show = true; + } + else + { + JoypacAdManager.Instance.HideBanner(); + text.text = "Banner"; + show = true; + show = false; + } + } +} diff --git a/popcorn/Assets/Examples/Scripts/BannerButton.cs.meta b/popcorn/Assets/Examples/Scripts/BannerButton.cs.meta new file mode 100644 index 00000000..a04d725d --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/BannerButton.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 70e15a32390af4068935f850828f3c2d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scripts/InterVideoButton.cs b/popcorn/Assets/Examples/Scripts/InterVideoButton.cs new file mode 100644 index 00000000..17456aba --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/InterVideoButton.cs @@ -0,0 +1,42 @@ + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; +using Joypac; +public class InterVideoButton : JPButton +{ + enum IVNumber + { + Inter1, + Inter2, + } + [SerializeField] + IVNumber iVNumber; + private void OnEnable() + { +#if !TWOINTER + if (iVNumber == IVNumber.Inter2) + { + this.gameObject.SetActive(false); + } +#endif + } + + public override void OnClick() + { + switch (iVNumber) + { + case IVNumber.Inter1: + JoypacAdManager.Instance.ShowInterstitial(null, ConstStringKey.JOYPAC_SDK_INTERID, "test1"); + break; + case IVNumber.Inter2: +#if TWOINTER + JoypacAdManager.Instance.ShowInterstitial(null, ConstStringKey.JOYPAC_SDK_INTERID2,"test2"); +#endif + break; + default: + break; + } + } +} diff --git a/popcorn/Assets/Examples/Scripts/InterVideoButton.cs.meta b/popcorn/Assets/Examples/Scripts/InterVideoButton.cs.meta new file mode 100644 index 00000000..03e7e747 --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/InterVideoButton.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a2947b0ff488544b48c0a4a3ebfc2939 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scripts/JoypacDemo.cs b/popcorn/Assets/Examples/Scripts/JoypacDemo.cs new file mode 100644 index 00000000..cf56841a --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/JoypacDemo.cs @@ -0,0 +1,11 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class JoypacDemo : MonoBehaviour +{ + private void Awake() + { + + } +} diff --git a/popcorn/Assets/Examples/Scripts/JoypacDemo.cs.meta b/popcorn/Assets/Examples/Scripts/JoypacDemo.cs.meta new file mode 100644 index 00000000..0c1ecd66 --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/JoypacDemo.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 564a0c6b3eeda4f7cbb643d11b22b309 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scripts/NativeButton.cs b/popcorn/Assets/Examples/Scripts/NativeButton.cs new file mode 100644 index 00000000..6388f149 --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/NativeButton.cs @@ -0,0 +1,36 @@ + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using Joypac; +using UnityEngine.UI; + +public class NativeButton : JPButton +{ + bool show = false; + [SerializeField] + private Text text = default; + [SerializeField] + NativeAd nativeAd; + public override void Start() + { + base.Start(); + text.text = "Native"; + } + public override void OnClick() + { + if (show == false) + { + nativeAd.ShowNativeAd(); + text.text = "HideNative"; + show = true; + } + else + { + JoypacAdManager.Instance.HideNative(false); + text.text = "Native"; + show = false; + } + + } +} diff --git a/popcorn/Assets/Examples/Scripts/NativeButton.cs.meta b/popcorn/Assets/Examples/Scripts/NativeButton.cs.meta new file mode 100644 index 00000000..36fd966b --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/NativeButton.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: d93a36bad8e9d43f288e5392cf291086 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scripts/RewardVideoButton.cs b/popcorn/Assets/Examples/Scripts/RewardVideoButton.cs new file mode 100644 index 00000000..978afbb0 --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/RewardVideoButton.cs @@ -0,0 +1,28 @@ + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; +using Joypac; +public class RewardVideoButton : JPButton +{ + public override void OnClick() + { + JPRewardAd.Instance.ShowRV("test", () => { PopupView.Show(null, false, "播放成功!可以给奖励!", true); }); + + + + + } + + + public void test() + { + JPRewardAd.Instance.ShowRV("test", success); + } + public void success() + { + //播放成功回调 + } + +} diff --git a/popcorn/Assets/Examples/Scripts/RewardVideoButton.cs.meta b/popcorn/Assets/Examples/Scripts/RewardVideoButton.cs.meta new file mode 100644 index 00000000..15b916bf --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/RewardVideoButton.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 90eba0ed596b44b86976d3ade08162d0 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Scripts/SettingPopViewButton.cs b/popcorn/Assets/Examples/Scripts/SettingPopViewButton.cs new file mode 100644 index 00000000..9d07aba3 --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/SettingPopViewButton.cs @@ -0,0 +1,39 @@ + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; +using Joypac; +#if UNITY_ANDROID +using JoyAdSigle = JoyPacCurrentcyAdSingle; +#endif +public class SettingPopViewButton : JPButton +{ +#if UNITY_ANDROID + private JoyAdSigle _currAdSigle; +#endif + public override void OnClick() + { +#if UNITY_IOS + JoypacAdClient.Instance.ShowSettingPopView(); +#elif UNITY_ANDROID +#if ANDROID_GP + return; +#endif + if (_currAdSigle != null) + _currAdSigle.showAgreementPermissionPop(); +#endif + } + + + + public void test() + { + // JPRewardAd.Instance.ShowRV("test", success); + } + public void success() + { + //播放成功回调 + } + +} diff --git a/popcorn/Assets/Examples/Scripts/SettingPopViewButton.cs.meta b/popcorn/Assets/Examples/Scripts/SettingPopViewButton.cs.meta new file mode 100644 index 00000000..f698f62c --- /dev/null +++ b/popcorn/Assets/Examples/Scripts/SettingPopViewButton.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 37e4f36d79aae43168d20938963a0b80 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Texture.meta b/popcorn/Assets/Examples/Texture.meta new file mode 100644 index 00000000..7074ee34 --- /dev/null +++ b/popcorn/Assets/Examples/Texture.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3b85081f5097b449eb5b24bcfdec855c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/Texture/沙滩背景.png b/popcorn/Assets/Examples/Texture/沙滩背景.png new file mode 100644 index 00000000..44f4f743 Binary files /dev/null and b/popcorn/Assets/Examples/Texture/沙滩背景.png differ diff --git a/popcorn/Assets/Examples/Texture/沙滩背景.png.meta b/popcorn/Assets/Examples/Texture/沙滩背景.png.meta new file mode 100644 index 00000000..f3fc1a20 --- /dev/null +++ b/popcorn/Assets/Examples/Texture/沙滩背景.png.meta @@ -0,0 +1,121 @@ +fileFormatVersion: 2 +guid: 91c7aa3bcdee0466f9efbf40c929f2e0 +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 9 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -100 + wrapU: 1 + wrapV: 1 + wrapW: -1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - serializedVersion: 2 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 56cf23676d44946ce88a87ad8eddfb1a + vertices: [] + indices: + edges: [] + weights: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/UI.meta b/popcorn/Assets/Examples/UI.meta new file mode 100644 index 00000000..6eb334f8 --- /dev/null +++ b/popcorn/Assets/Examples/UI.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6c79de43426684bbd91c017fc25a1be1 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/UI/Qq1.png b/popcorn/Assets/Examples/UI/Qq1.png new file mode 100644 index 00000000..0ae1659a Binary files /dev/null and b/popcorn/Assets/Examples/UI/Qq1.png differ diff --git a/popcorn/Assets/Examples/UI/Qq1.png.meta b/popcorn/Assets/Examples/UI/Qq1.png.meta new file mode 100644 index 00000000..28a78010 --- /dev/null +++ b/popcorn/Assets/Examples/UI/Qq1.png.meta @@ -0,0 +1,121 @@ +fileFormatVersion: 2 +guid: 976be38b9c2df456eb2181d33ac4d8de +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 9 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -100 + wrapU: 1 + wrapV: 1 + wrapW: -1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - serializedVersion: 2 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: b80896c05472a456eaff0f1281909aae + vertices: [] + indices: + edges: [] + weights: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/UI/bnt1.png b/popcorn/Assets/Examples/UI/bnt1.png new file mode 100644 index 00000000..322032af Binary files /dev/null and b/popcorn/Assets/Examples/UI/bnt1.png differ diff --git a/popcorn/Assets/Examples/UI/bnt1.png.meta b/popcorn/Assets/Examples/UI/bnt1.png.meta new file mode 100644 index 00000000..92529f01 --- /dev/null +++ b/popcorn/Assets/Examples/UI/bnt1.png.meta @@ -0,0 +1,121 @@ +fileFormatVersion: 2 +guid: 76313e85d379943bc9059b2dc49a0817 +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 9 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -100 + wrapU: 1 + wrapV: 1 + wrapW: -1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - serializedVersion: 2 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 743485857629c49748ed053a9e499334 + vertices: [] + indices: + edges: [] + weights: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Examples/UI/组 8 拷贝.png b/popcorn/Assets/Examples/UI/组 8 拷贝.png new file mode 100644 index 00000000..807feca1 Binary files /dev/null and b/popcorn/Assets/Examples/UI/组 8 拷贝.png differ diff --git a/popcorn/Assets/Examples/UI/组 8 拷贝.png.meta b/popcorn/Assets/Examples/UI/组 8 拷贝.png.meta new file mode 100644 index 00000000..c1591bf0 --- /dev/null +++ b/popcorn/Assets/Examples/UI/组 8 拷贝.png.meta @@ -0,0 +1,121 @@ +fileFormatVersion: 2 +guid: 9e0b71bcfadb24b4a8971140c9556bfe +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 9 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -100 + wrapU: 1 + wrapV: 1 + wrapW: -1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - serializedVersion: 2 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 4b5d3032b0db545f4b5b1a2a6c06dd75 + vertices: [] + indices: + edges: [] + weights: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JPChannel.meta b/popcorn/Assets/JPChannel.meta new file mode 100644 index 00000000..5aa33250 --- /dev/null +++ b/popcorn/Assets/JPChannel.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0eb58230e0e1342cc9bee58af2befb62 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JPChannel/Editor.meta b/popcorn/Assets/JPChannel/Editor.meta new file mode 100644 index 00000000..2731c084 --- /dev/null +++ b/popcorn/Assets/JPChannel/Editor.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dc9cd4f800d5e4d14acd3b6558efcbc9 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JPChannel/Editor/JPChannel.cs b/popcorn/Assets/JPChannel/Editor/JPChannel.cs new file mode 100644 index 00000000..fead8de7 --- /dev/null +++ b/popcorn/Assets/JPChannel/Editor/JPChannel.cs @@ -0,0 +1,438 @@ +//#define JPChannel_Save +using System; +using System.Collections.Generic; +using System.IO; +using UnityEditor; +using UnityEngine; +/*create by :闫婷婷 + * date :2020/7/9 + */ + +[Serializable] +public class JPChannelData +{ + public string button_text = ""; + public BuildTargetGroup buildTargetGroup = BuildTargetGroup.iOS; + public string info_plist_name = ""; + public string channel_macro_definition = ""; +} +[Serializable] +public class JPChannelAll +{ + public string info_target_path = ""; + public const string info_plist_name = "JoypacService-info.plist"; + public const string info_plist_file = "/" + "JPChannel" + "/" + "info" + "/"; + public JPChannelData[] channelDatas; +} +public class JPChannel : EditorWindow +{ + private static JPChannel window = null; + private static JPChannelAll channelAll; + private static string[] all = new string[2]; + private static string channel_path = "JPChannel"; + private static string channel_json_name = "channel.json"; + private static string info = "info"; + JPChannel() + { + this.titleContent = new GUIContent("Joypac Channel"); + + } + + [MenuItem("Tools/Change Channel")] + public static void ShowWindow() + { + ClearAll(); + window = EditorWindow.GetWindow(typeof(JPChannel)) as JPChannel; + //window.titleContent = new GUIContent("Change Channel"); + string path = Application.dataPath + "/" + channel_path; + + //已包含国内和海外两个渠道,如有其他渠道,在 "channel.json" 后边加入即可。 +#if JPChannel_Save + JPChannelAll b = new JPChannelAll(); + b.channelDatas = new JPChannelData[4]; + b.channelDatas[0] = new JPChannelData(); + b.channelDatas[1] = new JPChannelData(); + b.channelDatas[0].buildTargetGroup = BuildTargetGroup.Android; + b.channelDatas[0].button_text = "Andoird 国内"; + b.channelDatas[0].channel_macro_definition = "ANDROID_CN"; + b.channelDatas[1].buildTargetGroup = BuildTargetGroup.Android; + b.channelDatas[1].button_text = "Andoird 海外"; + b.channelDatas[1].channel_macro_definition = "ANDROID_GP"; + b.channelDatas[2] = new JPChannelData(); + b.channelDatas[3] = new JPChannelData(); + b.channelDatas[2].buildTargetGroup = BuildTargetGroup.iOS; + b.channelDatas[2].button_text = "iOS 国内"; + b.channelDatas[2].channel_macro_definition = "IOS_CN"; + b.channelDatas[2].buildTargetGroup = BuildTargetGroup.iOS; + b.channelDatas[3].button_text = "iOS 海外"; + b.channelDatas[3].channel_macro_definition = "IOS_OS"; + for (int i = 0; i < b.channelDatas.Length; ++i) + { + b.channelDatas[i].info_plist_name = b.channelDatas[i].channel_macro_definition+"_" + JPChannelAll.info_plist_name; + } + string str = JsonUtility.ToJson(b); + Debug.LogError(str); +#endif + if (Directory.Exists(path)) + { + path = path + "/" + channel_json_name; + if (File.Exists(path)) + { + string s = File.ReadAllText(path); + var b_data = JsonUtility.FromJson(s); + channelAll = b_data; +#if JPChannel_Save + string str1_data = JsonUtility.ToJson(channelAll); + Debug.LogError(str1_data); + all[0] = str; + System.IO.File.WriteAllLines(path, all); + AssetDatabase.SaveAssets(); +#endif + if (GetFile(new DirectoryInfo(Application.dataPath), JPChannelAll.info_plist_name) != null) + channelAll.info_target_path = GetFile(new DirectoryInfo(Application.dataPath), JPChannelAll.info_plist_name); + } + } + else + { + Debug.LogError(path); + AssetDatabase.CreateFolder("Assets", channel_path); + AssetDatabase.CreateFolder("Assets/" + channel_path, info); + } + } + + void OnGUI() + { + if (channelAll == null) + { + return; + } + //绘制标题 + GUILayout.Space(10); + GUI.skin.label.fontSize = 24; + GUI.skin.label.alignment = TextAnchor.MiddleCenter; + GUILayout.Label("Joypac Channel"); + GUI.skin.label.fontSize = 12; + GUI.skin.label.alignment = TextAnchor.MiddleLeft; + //绘制文本 + GUILayout.Space(10); + + +#if UNITY_IOS + + Change(BuildTargetGroup.iOS); +#elif UNITY_ANDROID + Change(BuildTargetGroup.Android); +#endif + } + public static void ClearAll() + { + n = 0; + radioInt = 0; + first = true; + } + + static bool need_differentiate; + static bool enable_iap; + static bool enable_cross; + static string ENABLE_IAP = "ENABLE_IAP"; + static string CROSS = "CROSS"; + static bool first = true; + static JPChannelData currentData; + static bool[] toggle = new bool[20]; + static int n = 0; + static int radioInt = 0; + public static void Change(BuildTargetGroup buildTargetGroup) + { + need_differentiate = EditorGUILayout.Toggle(buildTargetGroup + " 是否有多个渠道 ", need_differentiate); + GUILayout.Label("(例如:有国内海外两个渠道,或者其他两个至两个以上渠道)"); + + GUILayout.Space(10); + + if (need_differentiate) + { + + n = 0; + foreach (var ar in channelAll.channelDatas) + { + + if (ar.buildTargetGroup != buildTargetGroup) + { + continue; + } + //Debug.LogError(ar.button_text); + if (toggle[n] != GUI.Toggle(new Rect(25 + n * 120, 100, 100, 30), toggle[n], ar.button_text)) + { + bool value = toggle[n]; + toggle[n] = !value; + if (n != radioInt) + { + toggle[radioInt] = value; + radioInt = n; + } + if (toggle[n]) + { + first = true; + currentData = ar; + } + else + { + first = true; + currentData = null; + } + } + n++; + } + GUILayout.Space(40); + //Debug.LogError(currentData); + if (currentData == null) + { + GUILayout.Label("请选择一个渠道"); + return; + } + #region 设置开关 + + if (first) + { + first = false; + if (/*currentData.channel_macro_definition.Contains("_GP") ||*/ currentData.channel_macro_definition.Contains("_OS")) + { + enable_iap = true; + } + else + { + enable_iap = false; + } + //if (currentData.channel_macro_definition.Contains("ANDROID")) + //{ + enable_cross = false; + //} + //else + //{ + // enable_cross = true; + //} + } + enable_iap = EditorGUILayout.Toggle(enable_iap + " Enable_IAP ", enable_iap); + enable_cross = EditorGUILayout.Toggle(enable_cross + " Enable_CROSS ", enable_cross); + + #endregion + + + if (GUILayout.Button(currentData.button_text)) + { + String sourcePath = Application.dataPath + JPChannelAll.info_plist_file + currentData.info_plist_name; + String targetPath = channelAll.info_target_path; + bool isrewrite = true; // true=覆盖已存在的同名文件,false则反之 + if (File.Exists(sourcePath) && targetPath != null) + { + System.IO.File.Copy(sourcePath, targetPath, isrewrite); + Debug.Log("change " + JPChannelAll.info_plist_name + " to " + currentData.channel_macro_definition + " success "); + } + else + { + Debug.LogError("please check '" + sourcePath + "' and '" + targetPath + "',Does it exist?"); + } + string str = PlayerSettings.GetScriptingDefineSymbolsForGroup(currentData.buildTargetGroup); + Debug.Log("old " + str); + str = str.Replace(';' + ENABLE_IAP, null); + str = str.Replace(';' + CROSS, null); + if (enable_iap) str = ENABLE_IAP + ";" + str; + if (enable_cross) str = CROSS + ";" + str; + + for (int i = 0; i < channelAll.channelDatas.Length; ++i) + { + str = str.Replace(channelAll.channelDatas[i].channel_macro_definition, null); + } + PlayerSettings.productName = SettingStringsKey.Instance.productName; + Debug.Log("Change productName to " + SettingStringsKey.Instance.productName); + PlayerSettings.SetScriptingDefineSymbolsForGroup(currentData.buildTargetGroup, + currentData.channel_macro_definition + ";" + str); + Debug.Log("new " + PlayerSettings.GetScriptingDefineSymbolsForGroup(currentData.buildTargetGroup)); + PlayerSettings.SetApplicationIdentifier(buildTargetGroup, SettingStringsKey.Instance.BundleID); + Debug.Log("Change bundleID to " + SettingStringsKey.Instance.BundleID); +#if UNITY_IOS + PlayerSettings.iOS.appleDeveloperTeamID = SettingStringsKey.Instance.DeveloperTeamID; + string china = Application.dataPath + "/" + JoypacConst.thirdPath + "pangle_China"; + //string china_hide = Application.dataPath + "/" + JoypacConst.thirdPath + "Pangle/China~"; + string global = Application.dataPath + "/" + JoypacConst.thirdPath + "pangle_nonChina"; + //string global_hide = Application.dataPath + "/" + JoypacConst.thirdPath + "Pangle/Global~"; + if (currentData.channel_macro_definition.Contains("_OS")) + { + HidePath(china); + ShowPath(global); + Debug.Log("头条要区分国内国外"); + } + else if (currentData.channel_macro_definition.Contains("_CN")) + { + HidePath(global); + ShowPath(china); + Debug.Log("头条要区分国内国外"); + } +#endif + PlayerSettings.bundleVersion = SettingStringsKey.Instance.bundleVersion; + Debug.Log("Change bundleVersion to " + SettingStringsKey.Instance.bundleVersion); +#if UNITY_ANDROID + //以下属于海外 + if (currentData.channel_macro_definition.Contains("_GP") || currentData.channel_macro_definition.Contains("_CY") + || currentData.channel_macro_definition.Contains("_HW") || currentData.channel_macro_definition.Contains("_QZ")) + { + PlayerSettings.Android.targetSdkVersion = AndroidSdkVersions.AndroidApiLevelAuto; + Debug.Log("Change targetSdkVersion to " + AndroidSdkVersions.AndroidApiLevelAuto); + } + else//其余属于国内 + { + PlayerSettings.Android.targetSdkVersion = AndroidSdkVersions.AndroidApiLevel28; + Debug.Log("Change targetSdkVersion to " + AndroidSdkVersions.AndroidApiLevel28); + } +#endif + + Debug.Log("Change " + " to " + currentData.button_text + " Success"); + } + + + } + else + { + GUILayout.Label(buildTargetGroup + "不需要多个渠道的话,不需要更改Channel,可以关闭此页面啦!"); + return; + } + } + //public static void RemoveHidePath(string showPath) + //{ + // if (System.IO.Directory.Exists(showPath)) + // { + // //删除隐藏 + // if (System.IO.Directory.Exists(showPath+"~")) + // { + // Debug.LogError(" 存在 删除文件夹 " + showPath + "~"); + + // // System.IO.Directory.Delete(@updateAssets.list[0].LocalUrl); + // try + // { + // var dir = new System.IO.DirectoryInfo(showPath + "~"); + // dir.Attributes = dir.Attributes & ~FileAttributes.ReadOnly; + // dir.Delete(true); + // } + // catch (Exception ex) + // { + // Debug.LogError(string.Format(" 文件夹存在 删除文件夹时 出现错误 【{0}】", ex.Message)); + // } + // } + // } + // else if(System.IO.Directory.Exists(showPath+"~")) + // { + // System.IO.Directory.Move(showPath + "~", showPath); + // } + // else + // { + // Debug.LogError("不存在 " + showPath); + // } + + //} + + + public static void HideFile(string path) + { + if (File.Exists(path)) + { + File.Move(path, path + "~"); + } + else + { + Debug.LogError("不存在 " + path); + } + } + + public static void HidePath(string path) + { + if (System.IO.Directory.Exists(path)) + { + System.IO.Directory.Move(path, path + "~"); + } + else if (System.IO.Directory.Exists(path + "~")) + { + + } + else + { + Debug.LogError("不存在 " + path); + } + + } + + public static void showFile(string path) + { + if (File.Exists(path)) + { + + } + else if (File.Exists(path + "~")) + { + File.Move(path + "~", path); + } + else + { + Debug.LogError("不存在 " + path); + } + } + public static void ShowPath(string path) + { + if (System.IO.Directory.Exists(path)) + { + + } + else if (System.IO.Directory.Exists(path + "~")) + { + System.IO.Directory.Move(path + "~", path); + } + else + { + Debug.LogError("不存在 " + path); + } + + } + public static void GetFiles(DirectoryInfo directory, string pattern, ref List fileList) + { + if (directory != null && directory.Exists && !string.IsNullOrEmpty(pattern)) + { + try + { + foreach (FileInfo info in directory.GetFiles(pattern)) + { + string path = info.FullName.ToString(); + fileList.Add(path.Substring(path.IndexOf("Assets"))); + } + } + catch (System.Exception) + { + throw; + } + foreach (DirectoryInfo info in directory.GetDirectories()) + { + GetFiles(info, pattern, ref fileList); + } + } + } + public static string GetFile(DirectoryInfo directory, string pattern) + { + List prefafbPathList = new List(); + GetFiles(directory, pattern, ref prefafbPathList); + if (prefafbPathList.Count == 1) + { + //Debug.LogError(prefafbPathList[0]); + return prefafbPathList[0]; + } + else if (prefafbPathList.Count > 1) + { + Debug.LogError("存在多个 " + pattern + " 是错误的"); + + } + else + { + Debug.LogError("没有找到 " + pattern + " 是否因为JPsdk版本低,暂不支持"); + } + + return null; + } + +} + diff --git a/popcorn/Assets/JPChannel/Editor/JPChannel.cs.meta b/popcorn/Assets/JPChannel/Editor/JPChannel.cs.meta new file mode 100644 index 00000000..06ddcd58 --- /dev/null +++ b/popcorn/Assets/JPChannel/Editor/JPChannel.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 034e08316962c44f7957eccfcf72275d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JPChannel/channel.json b/popcorn/Assets/JPChannel/channel.json new file mode 100644 index 00000000..e08aa0c5 --- /dev/null +++ b/popcorn/Assets/JPChannel/channel.json @@ -0,0 +1,2 @@ +{"info_target_path":"","channelDatas":[{"button_text":"Andoird 国内","buildTargetGroup":7,"info_plist_name":"ANDROID_CN_JoypacService-info.plist","channel_macro_definition":"ANDROID_CN"},{"button_text":"Andoird 海外","buildTargetGroup":7,"info_plist_name":"ANDROID_GP_JoypacService-info.plist","channel_macro_definition":"ANDROID_GP"},{"button_text":"iOS 国内","buildTargetGroup":4,"info_plist_name":"IOS_CN_JoypacService-info.plist","channel_macro_definition":"IOS_CN"},{"button_text":"iOS 海外","buildTargetGroup":4,"info_plist_name":"IOS_OS_JoypacService-info.plist","channel_macro_definition":"IOS_OS"}]} + diff --git a/popcorn/Assets/JPChannel/channel.json.meta b/popcorn/Assets/JPChannel/channel.json.meta new file mode 100644 index 00000000..b6167a1b --- /dev/null +++ b/popcorn/Assets/JPChannel/channel.json.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 7a455ccca671b41b0a5beef4fb6e2ef6 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JPChannel/info.meta b/popcorn/Assets/JPChannel/info.meta new file mode 100644 index 00000000..628cc25e --- /dev/null +++ b/popcorn/Assets/JPChannel/info.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 01ea5f3fcb26d441ca2abd9cb81d2dc0 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JPChannel/info/iOS_CN_JoypacService-info.plist b/popcorn/Assets/JPChannel/info/iOS_CN_JoypacService-info.plist new file mode 100644 index 00000000..deb00765 --- /dev/null +++ b/popcorn/Assets/JPChannel/info/iOS_CN_JoypacService-info.plist @@ -0,0 +1,36 @@ + + + + + JoypacAppId + 0cc787bfde + JoypacAppName + 打败小偷 + topOnAppId + a5e5cd93c49329 + topOnAppKey + d78b587989ce58c20e6df748f53e3f31 + bannerStatus + 1 + bannerPlacement + b5e5cdc1c064e4 + nativeStatus + 1 + nativePlacement + b5e5cdbfeb5771 + splashStatus + 1 + splashPlacement + b5e5cdc0cd7d74 + JPSplashPlacement + 打败小偷SP + rewardVideoStatus + 1 + rewardVideoPlacement + b5e5cdb8fb04d7 + interstitialConfig + [{"adOrder": "1", "maxTimeInterval": "0", "minTimeInterval": "0", "status": "1", "unitID": "b5e5cdba1689cf", "name": "打败小偷IV"}] + Channel + CN + + diff --git a/popcorn/Assets/JPChannel/info/iOS_CN_JoypacService-info.plist.meta b/popcorn/Assets/JPChannel/info/iOS_CN_JoypacService-info.plist.meta new file mode 100644 index 00000000..b3be27b6 --- /dev/null +++ b/popcorn/Assets/JPChannel/info/iOS_CN_JoypacService-info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 2632024f3dffe4e608641570dee45a1e +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JPChannel/info/iOS_OS_JoypacService-info.plist b/popcorn/Assets/JPChannel/info/iOS_OS_JoypacService-info.plist new file mode 100644 index 00000000..2f31e463 --- /dev/null +++ b/popcorn/Assets/JPChannel/info/iOS_OS_JoypacService-info.plist @@ -0,0 +1,36 @@ + + + + + JoypacAppId + 0cc787bfde + JoypacAppName + 打败小偷 + topOnAppId + a5e5cd93c49329 + topOnAppKey + d78b587989ce58c20e6df748f53e3f31 + bannerStatus + 1 + bannerPlacement + b5e5cdc1c064e4 + nativeStatus + 1 + nativePlacement + b5e5cdbfeb5771 + splashStatus + 1 + splashPlacement + b5e5cdc0cd7d74 + JPSplashPlacement + 打败小偷SP + rewardVideoStatus + 1 + rewardVideoPlacement + b5e5cdb8fb04d7 + interstitialConfig + [{"adOrder": "1", "maxTimeInterval": "0", "minTimeInterval": "0", "status": "1", "unitID": "b5e5cdba1689cf", "name": "打败小偷IV"}] + Channel + OS + + diff --git a/popcorn/Assets/JPChannel/info/iOS_OS_JoypacService-info.plist.meta b/popcorn/Assets/JPChannel/info/iOS_OS_JoypacService-info.plist.meta new file mode 100644 index 00000000..686ddcca --- /dev/null +++ b/popcorn/Assets/JPChannel/info/iOS_OS_JoypacService-info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 463aa8548b03c407db88bad6a5f917bb +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK.meta b/popcorn/Assets/JoyPacSDK.meta new file mode 100644 index 00000000..66604704 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 35b92a92885e848328b3b9110894b217 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core.meta b/popcorn/Assets/JoyPacSDK/Core.meta new file mode 100644 index 00000000..50832e47 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0167bb673c7b04d1cb3ca0a1451ef38f +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation.meta b/popcorn/Assets/JoyPacSDK/Core/Automation.meta new file mode 100644 index 00000000..260f7c88 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cb2477510ad394b8ea412b2b9b2e39a2 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute.meta new file mode 100644 index 00000000..8091ae8e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e23b716a8b7e24f029f641fca9177ec0 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/InspectorGameParamsAttribute.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/InspectorGameParamsAttribute.cs new file mode 100644 index 00000000..9fa89d8c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/InspectorGameParamsAttribute.cs @@ -0,0 +1,49 @@ +using System; + + +[AttributeUsage(AttributeTargets.Field)] +public class InspectorGameParamsAttribute : Attribute +{ + // 当前属性是面向哪个平台 + public readonly JPEditorPlatformType PlatformType; + + //当前发布平台 + public readonly JPReleaseAreaType ReleasePlatformType; + + + + // 当前属性隶属于哪个组件 + public readonly JPEditorComponentType ComponentType; + + // 当前属性在面板中显示的名字 + public readonly string InspectorPropertyLabel; + + // 参数在目标平台中对应的key + public readonly string TargetPlatformParameterKey; + // tip + public readonly string Tip; + // 当前属性是否为控制开关,控制其他参数在面板中展示或隐藏 + public readonly bool IsControllerSwitch; + + // 具体平台参数的属性注解 + public InspectorGameParamsAttribute( + JPEditorPlatformType platformType, + JPReleaseAreaType releasePlatformType, + + JPEditorComponentType componentType, + string inspectorPropertyLabel, + string targetPlatformParameterKey = "", + bool isControllerSwitch = false, + string tip = null) + { + this.PlatformType = platformType; + this.ComponentType = componentType; + this.ReleasePlatformType = releasePlatformType; + + this.InspectorPropertyLabel = inspectorPropertyLabel; + this.TargetPlatformParameterKey = targetPlatformParameterKey; + this.IsControllerSwitch = isControllerSwitch; + Tip = tip; + } +} + diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/InspectorGameParamsAttribute.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/InspectorGameParamsAttribute.cs.meta new file mode 100644 index 00000000..b9b3d42d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/InspectorGameParamsAttribute.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 502948ed643046a5bb7d9fb0e1da55ba +timeCreated: 1615346407 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorComponentType.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorComponentType.cs new file mode 100644 index 00000000..32eab3f3 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorComponentType.cs @@ -0,0 +1,19 @@ + +public enum JPEditorComponentType +{ + Core,// 基础核心模块 + JoyPacSetting, + Pop_Up, + AdParams,// Core-Ad-Params + AdNet,// 广告网络,穿山甲、广点通、百度等等... + Ga_Adjust,// 账号模块 + AdjustEvent, + Push,// Push模块 + Att,//att弹框模块,仅在无jPframework的情况使用 + Umeng, + GamePlatform, // 摸摸鱼平台 + Build,// 构建模块 + BuildPush,//如果有push模块,构建参数需要增加一个推送证书 + + Properties, +} diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorComponentType.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorComponentType.cs.meta new file mode 100644 index 00000000..5a372d02 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorComponentType.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 78ab155ba47141378ea9b3624619b069 +timeCreated: 1615359007 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorPlatformType.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorPlatformType.cs new file mode 100644 index 00000000..561abda9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorPlatformType.cs @@ -0,0 +1,32 @@ +using System.ComponentModel; +using UnityEngine; + +public enum JPEditorPlatformType +{ + // 安卓平台 + Android, + + // iOS平台 + iOS, + + Editor, +} +public enum JPReleaseAreaType +{ + [HideInInspector] + Editor, + + [Description("China")] + CN,//国内 + + + [Description("no China")] + OS,//海外 +} + +//public enum JPReleasePeriod +//{ + +// // 正式发行阶段, +// 正式发行阶段 +//} diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorPlatformType.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorPlatformType.cs.meta new file mode 100644 index 00000000..98cf6c49 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Attribute/JPEditorPlatformType.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: fc4d55939b64416cb5d8a9bb3d8b7872 +timeCreated: 1615346582 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/AutomationManager.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/AutomationManager.cs new file mode 100644 index 00000000..2238b708 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/AutomationManager.cs @@ -0,0 +1,90 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Reflection; +using UnityEditor; + +#if UNITY_EDITOR + + +/// +/// 自动化管理类. +/// +public static class AutomationManager +{ + // 所有自动化prefab的存储路径 + private static string PrefabPath = Path.Combine(JPPackageManager.AutomationPluginsRelativePath, "Editor/Prefab"); + + // 游戏初始化参数prefab存放的位置,此prefab中会存放所有初始化参数 + private static string JoyPacInitParamsPrefabPath = Path.Combine(PrefabPath, "JoyPacInitParams.prefab"); + + // 构建参数prefab路径 + private static string JoyPacBuildParamsPrefabPath = Path.Combine(PrefabPath, "JoyPacBuildParams.prefab"); + + // 保存单个class中的所有字段信息 + private static Dictionary> AllFieldInfo = new Dictionary>(); + + + // 获取游戏中配置的参数 + public static JoyPacParams JoyPacParams => JoyPacParams.Instance; + // 获取游戏中配置的构建参数 + public static JoyPacBuildParams JoyPacBuildParams => JoyPacBuildParams.Instance; + + // 获取所有有效字段信息(添加了注解的信息) + public static IEnumerable GetValidFieldInfo(Type type) + where T : class + { + if (AllFieldInfo.ContainsKey(type)) + { + return AllFieldInfo[type]; + } + + // 读取所有字段信息 + var fieldInfos = type.GetFields(); + + if (fieldInfos.Length > 0) + { + var validFieldInfos = new List(); + foreach (var fieldInfo in fieldInfos) + { + // 自定义了属性则代表有效属性 + var inspectorGameParamsAttribute = GetAttr(fieldInfo); + if (inspectorGameParamsAttribute != null) + { + validFieldInfos.Add(fieldInfo); + } + } + + AllFieldInfo.Add(type, validFieldInfos); + return AllFieldInfo[type]; + } + + return null; + } + + // 通过字段信息获取字段中的自定义注解对象 + public static T GetAttr(ICustomAttributeProvider fieldInfo) + where T : class + { + // 第二个参数代表,是否获取父类中的字段 + var customAttributes = fieldInfo.GetCustomAttributes(typeof(T), false); + if (customAttributes.Length > 0) + { + return customAttributes[0] as T; + } + + return null; + } + + // 获取prefab中引用的对象 + private static T GetPrefabObj(string prefabPath) + where T : class + { + var JoyPacParams = AssetDatabase.LoadAssetAtPath(prefabPath, typeof(T)) as T; + return JoyPacParams; + } + + +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/AutomationManager.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/AutomationManager.cs.meta new file mode 100644 index 00000000..11610ec1 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/AutomationManager.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 17a974cd78e834ab59eaf636bc75eabf +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor.meta new file mode 100644 index 00000000..c73df22e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 12aba9b62c46454fb424412296ac3601 +timeCreated: 1617334267 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build.meta new file mode 100644 index 00000000..c783964d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: df924547ac3d4cb983c752c0a9fe8a03 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildListener.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildListener.cs new file mode 100644 index 00000000..c45924ea --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildListener.cs @@ -0,0 +1,60 @@ +using System.IO; +using System.Threading; +using UnityEditor.Android; +using UnityEditor.Build; +using UnityEditor.Build.Reporting; +using UnityEngine; + + +public class BuildListener : IPreprocessBuildWithReport, IPostprocessBuildWithReport, IPostGenerateGradleAndroidProject +{ + public int callbackOrder => 0; + + public void OnPreprocessBuild(BuildReport report) + { + + + UnityEngine.Debug.Log("[JoyPacSDK]: Prepare before packing"); +#if UNITY_ANDROID + Properties.chackProperties(); + JPPackageManager.chackPath(); + + +#endif + + + + + } + + public void OnPostprocessBuild(BuildReport report) + { + + } + + public void OnPostGenerateGradleAndroidProject(string path) + { + //Debug.Log("OnPostGenerateGradleAndroidProject"); + //Debug.Log("Bulid path : " + path); + //string path_ = Path.GetFullPath(".."); + //Debug.Log("Bulid path : " + path_); + //string gradlePropertiesFile = path_ + "/gradle/wrapper/gradle-wrapper.properties"; + //if (File.Exists(gradlePropertiesFile)) + //{ + // File.Delete(gradlePropertiesFile); + //} + //StreamWriter writer = File.CreateText(gradlePropertiesFile); + //writer.WriteLine("distributionBase=GRADLE_USER_HOME"); + //writer.WriteLine("distributionPath=wrapper/dists"); + //writer.WriteLine("distributionUrl=https'\'://services.gradle.org/distributions/gradle-6.1.1-all.zip"); + + //writer.WriteLine("zipStoreBase=GRADLE_USER_HOME"); + //writer.WriteLine("zipStorePath=wrapper/dists"); + //writer.Flush(); + //writer.Close(); + + + } + +} + diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildListener.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildListener.cs.meta new file mode 100644 index 00000000..ac253fce --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildListener.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: bd1bf8bc0ecf4aae88c1a65e45934fc0 +timeCreated: 1620632638 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildScriptManager.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildScriptManager.cs new file mode 100644 index 00000000..3b7e1652 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildScriptManager.cs @@ -0,0 +1,131 @@ +#if UNITY_EDITOR +using System; +using System.Diagnostics; +using System.IO; +using System.Text; +using Debug = UnityEngine.Debug; + +public static class BuildScriptManager +{ + // Android构建脚本路径 + private static string AndroidBuildScriptPath = Path.Combine( + Environment.CurrentDirectory, + Path.Combine(JPPackageManager.AutomationPluginsRelativePath, "Editor/Build/Editor_Android/export_apk.sh")); + + // iOS构建脚本路径 + private static string iOSBuildScriptPath = Path.Combine( + Environment.CurrentDirectory, + Path.Combine(JPPackageManager.AutomationPluginsRelativePath, "Editor/Build/Editor_iOS/export_ipa.sh")); + + // unity加载完成后,修改构建脚本中的内容 + public static void UpdateBuildScriptContent() + { + UpdatePlatformScript(AndroidBuildScriptPath, true); + UpdatePlatformScript(iOSBuildScriptPath); + } + + // 修改构建脚本中Unity路径. + private static void UpdatePlatformScript(string filePath, bool isAndroid = false) + { + try + { + if (!File.Exists(filePath)) + { + // ignore,文件不存在直接返回. + return; + } + + var readAllLines = File.ReadAllLines(filePath); + + var isUpdate = false; + for (var i = 0; i < readAllLines.Length; i++) + { + var lineText = readAllLines[i]; + // 1. 动态修改构建脚本中当前unity开发工具路径 + var processModule = Process.GetCurrentProcess().MainModule; + if (processModule != null) + { + var newIdeText = "UNITY_PATH=" + processModule.FileName; + + if (lineText.Contains("UNITY_PATH=") && lineText != newIdeText) + { + readAllLines[i] = newIdeText; + isUpdate = true; + } + } + + // 动态修改构建脚本中相对路径 + var newSdkRelativePath = + "CurrentScriptRelativePath=" + JPPackageManager.AutomationPluginsRelativePath + + (isAndroid ? "/Editor/Build/Editor_Android" : "/Editor/Build/Editor_iOS"); + + if (lineText.Contains("CurrentScriptRelativePath=") && lineText != newSdkRelativePath) + { + readAllLines[i] = newSdkRelativePath; + isUpdate = true; + } + } + + if (isUpdate) + { + File.WriteAllLines(filePath, readAllLines, Encoding.UTF8); + } + } + catch (Exception e) + { + Debug.LogError(e); + } + } + + /// + /// 修改文件脚本 + /// + /// 文件路径. + /// 文件中的key. + /// 文件中的value. + /// 仅仅修改找到的第一个key. + public static void UpdateFileScript(string filePath, string key, string value, bool onlyUpdateFirstKey) + { + try + { + if (!File.Exists(filePath)) + { + // ignore,文件不存在直接返回. + return; + } + + var readAllLines = File.ReadAllLines(filePath); + + var isUpdate = false; + for (var i = 0; i < readAllLines.Length; i++) + { + var lineText = readAllLines[i]; + + if (lineText.Contains(key)) + { + if (lineText != value) + { + readAllLines[i] = value; + isUpdate = true; + } + + if (onlyUpdateFirstKey) + { + break; + } + } + } + + if (isUpdate) + { + File.WriteAllLines(filePath, readAllLines, Encoding.UTF8); + } + } + catch (Exception e) + { + Debug.LogError(e); + } + } +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildScriptManager.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildScriptManager.cs.meta new file mode 100644 index 00000000..f523a780 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/BuildScriptManager.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 9c3381394b9943bbb7664a9b23d97e56 +timeCreated: 1616150664 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android.meta new file mode 100644 index 00000000..25739f72 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d38e533214b644b53910626ba7a05f8b +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/AndroidPlatformPostProcess.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/AndroidPlatformPostProcess.cs new file mode 100644 index 00000000..cf0f854a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/AndroidPlatformPostProcess.cs @@ -0,0 +1,86 @@ +using System.IO; +using System.Xml; +using UnityEditor; +using UnityEditor.Android; +using UnityEditor.Callbacks; +using UnityEngine; + +#if UNITY_EDITOR + +internal class AndroidPlatformPostProcess +{ + + + + + [PostProcessBuild(999)] + public static void OnPostProcessBuild(BuildTarget target, string pathToBuiltProject) + { + if (target == BuildTarget.Android) + { + UnityEngine.Debug.Log("[JoyPacSDK]: Starting to perform post build tasks for Android platform."); + Debug.Log(pathToBuiltProject); + RunPostProcessTasksAndroid(pathToBuiltProject); + + } + } + + private static void RunPostProcessTasksAndroid(string path) + { + + + //Debug.Log("Bulid path : " + path); + //string appRawPath = Path.Combine(path, "unityLibrary/src/main/res/raw"); + + //string appPropertiesPath = Path.Combine(path, "unityLibrary/src/main/res/raw/joypac_games_config.properties"); + + //string JoyPacPropertiesPath = Application.dataPath + "/JoyPacSDK/Core/Plugins/Android/joypac_games_config.properties"; + + //if (File.Exists(JoyPacPropertiesPath)) + //{ + // if (!Directory.Exists(appRawPath)) + // { + + // Directory.CreateDirectory(appRawPath); + // } + + // File.Copy(JoyPacPropertiesPath, appPropertiesPath); + //} + //else + // Debug.LogError(JoyPacPropertiesPath + " 文件不存在,请重新生成后重新打包"); + + + + + + + + + + + + //string gradlePropertiesFile = path + "/gradle/wrapper/gradle-wrapper.properties"; + //Debug.Log(File.Exists(gradlePropertiesFile)); + ////if (File.Exists(gradlePropertiesFile)) + //{ + // File.Delete(gradlePropertiesFile); + //} + //StreamWriter writer = File.CreateText(gradlePropertiesFile); + //writer.WriteLine("distributionBase=GRADLE_USER_HOME"); + //writer.WriteLine("distributionPath=wrapper/dists"); + //writer.WriteLine("distributionUrl=https'\'://services.gradle.org/distributions/gradle-6.1.1-all.zip"); + + //writer.WriteLine("zipStoreBase=GRADLE_USER_HOME"); + //writer.WriteLine("zipStorePath=wrapper/dists"); + //writer.Flush(); + //writer.Close(); + + + + + } + + +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/AndroidPlatformPostProcess.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/AndroidPlatformPostProcess.cs.meta new file mode 100644 index 00000000..bb167a4c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/AndroidPlatformPostProcess.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4b037c6c676ba4585b471779fcab66cc +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/BuildApk.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/BuildApk.cs new file mode 100644 index 00000000..d2dd2515 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/BuildApk.cs @@ -0,0 +1,124 @@ +#if UNITY_EDITOR +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.IO; +using System.Threading; +using UnityEditor; +using UnityEditor.Build.Reporting; +using UnityEngine; +using Debug = UnityEngine.Debug; + +// 此处的命名空间也要写在shell脚本中!!!,否则找不到此class +namespace ByteDance.Union +{ + public static class BuildApk + { + // 项目根目录,assets上一级目录 + private static string ProjectRootDir = Environment.CurrentDirectory; + + // 项目构建目录 + private static string ProjectBuildDir = Path.Combine(ProjectRootDir, "BuildProductDir"); + + // apk目录 + private static string ApkPath = + Path.Combine(ProjectBuildDir, "Android/Products/" + Application.productName + ".apk"); + + //[MenuItem(JPMenuName.BUILD_DEBUG_APK)] + public static void BuildDebug() + { + Build(true); + } + + // [MenuItem(JPMenuName.BUILD_RELEASE_APK)] + public static void BuildRelease() + { + Build(); + } + + private static void Build(bool isDebug = false) + { + var buildPlayerOptions = default(BuildPlayerOptions); + buildPlayerOptions.scenes = GetBuildScenes(); + buildPlayerOptions.target = BuildTarget.Android; + buildPlayerOptions.targetGroup = BuildTargetGroup.Android; + buildPlayerOptions.locationPathName = ApkPath; + buildPlayerOptions.options = + isDebug + ? (BuildOptions.Development | BuildOptions.ConnectWithProfiler | BuildOptions.AllowDebugging) + : BuildOptions.None; + + var buildReport = BuildPipeline.BuildPlayer(buildPlayerOptions); + + var summary = buildReport.summary; + if (summary.result == BuildResult.Succeeded) + { + Debug.Log("Build Apk successes "); + var thread = new Thread(InstallApk); + thread.Start(); + } + else if (summary.result == BuildResult.Failed) + { + Debug.LogError("Build Apk failed : " + summary.totalErrors); + } + else if (summary.result == BuildResult.Cancelled) + { + Debug.Log("Build Apk cancelled"); + } + else if (summary.result == BuildResult.Unknown) + { + Debug.Log("Build Apk Unknown..."); + } + } + + // 安装apk + private static void InstallApk() + { + ExecuteCommandScript("adb install -r " + ApkPath); + } + + // 执行shell 命令 + private static void ExecuteCommandScript(string command) + { + // 配置命令信息,准备执行脚本 + var psi = new ProcessStartInfo(); + psi.FileName = "bash"; + psi.UseShellExecute = false; + psi.Arguments = command; + + // 执行对应的shell脚本 + var process = Process.Start(psi); + if (process != null) + { + process.WaitForExit(); + process.Close(); + } + else + { + Debug.LogError(command + " execute error..."); + } + } + + // 找出所有需要构建的场景 + private static string[] GetBuildScenes() + { + var names = new List(); + + foreach (var settingsScene in EditorBuildSettings.scenes) + { + if (settingsScene == null) + { + continue; + } + + if (settingsScene.enabled) + { + names.Add(settingsScene.path); + } + } + + return names.ToArray(); + } + } +} +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/BuildApk.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/BuildApk.cs.meta new file mode 100644 index 00000000..cfedd9b1 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/BuildApk.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 89180fb28336945eca2b998d9cdd9a3a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/export_apk.sh b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/export_apk.sh new file mode 100644 index 00000000..ae2c78df --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/export_apk.sh @@ -0,0 +1,54 @@ +#!/bin/sh + +# 构建类型,Release 或 Debug +BuildType=$1 + +# 打印日志方法 +# shellcheck disable=SC2112 +function PrintLog() { + echo "============== $1 ==============" +} + +# 检查是否传入了参数,如果传未传入参数则赋予默认值为Release +if [ ! "$1" ]; then + PrintLog "BuildType is null,default release" + BuildType="Release" +else + PrintLog "BuildType is "${BuildType} +fi + +# 当前脚本所在路径 +CurrentScriptPath=$(dirname "$0") + +# 当前脚本所在的相对路径 +CurrentScriptRelativePath=Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android + +# project path +# shellcheck disable=SC2039 +PROJ_PATH=${CurrentScriptPath//${CurrentScriptRelativePath}//""} + +# 去掉项目路径中最后一个字符"/" +PROJ_PATH=${PROJ_PATH%?} + +# unity app path +UNITY_PATH=/Applications/Unity/Hub/Editor/2019.4.19f1/Unity.app/Contents/MacOS/Unity + +# 构建日志的输出路径 +LOG_PATH=$PROJ_PATH/BuildProductDir/Android/Log/BuildApk.log + +# log日志输出目录 +PrintLog "LOG_PATH = "${LOG_PATH} + +PrintLog "Unity Build Apk Begin" + +if [ ${BuildType} = "Release" ]; then + # 构建release apk + PrintLog "Build Release Apk" + $UNITY_PATH -projectPath $PROJ_PATH -executeMethod ByteDance.Union.BuildApk.BuildRelease -logFile $LOG_PATH -batchMode -quit +else + # 构建debug apk + PrintLog "Build Debug Apk" + $UNITY_PATH -projectPath $PROJ_PATH -executeMethod ByteDance.Union.BuildApk.BuildDebug -logFile $LOG_PATH -batchMode -quit +fi + +PrintLog "Unity Build Apk Finished" diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/export_apk.sh.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/export_apk.sh.meta new file mode 100644 index 00000000..f6ba621b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_Android/export_apk.sh.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: e54183835bff143b5b514f1b68285059 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS.meta new file mode 100644 index 00000000..d4d2acff --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f2b4cd3af3604fecbed326f87403169c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/BuildIpa.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/BuildIpa.cs new file mode 100644 index 00000000..12672d95 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/BuildIpa.cs @@ -0,0 +1,293 @@ +// mac 电脑才可以打包ipa +#if UNITY_EDITOR_OSX && UNITY_IOS +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.IO; +using UnityEditor; +using UnityEditor.Build.Reporting; +using Debug = UnityEngine.Debug; + +public static class BuildIpa +{ + // 项目根目录,assets上一级目录 + private static string ProjectRootDir = Environment.CurrentDirectory; + + // 项目构建目录 + private static string ProjectBuildDir = Path.Combine(ProjectRootDir, "BuildProductDir"); + + // xcode构建目录 + private static string XcodeDir = Path.Combine(ProjectBuildDir, "iOS/XcodeProjectDir"); + + // ios 构建产物路径 + private static string iOSProductsPath = Path.Combine(ProjectBuildDir, "iOS/Products"); + + // 准备信息 + private static string iOSPrepareInfoPath = Path.Combine(ProjectBuildDir, "iOS/PrepareInfo"); + + // 导出ipa所需要的配置文件,shell脚本中会用到此文件 + private static string ExportOptionsInfoPath = + Path.Combine(iOSPrepareInfoPath, "ExportOptions.plist"); + + // 构建脚本路径 + private static string BuildIpaScriptPath = Path.Combine( + JPPackageManager.GetComponentDir(JPComponenetType.Core), + "Automation/Editor/Build/Editor_iOS/export_ipa_from_xcode_project.sh"); + + private static string BuildType_Debug = "Debug"; + private static string BuildType_Release = "Release"; + + // 当前构建类型 + private static string CurrentBuildType; + + + //[MenuItem(JPMenuName.BUILD_DEBUG_IPA)] + public static void BuildDebug() + { + BuildSummary summary = Export(BuildType_Debug); + if (summary.result == BuildResult.Succeeded) + { + RunBuildIpaShell(); + } + else + { + EditorUtility.DisplayDialog("Xcode 工程导出失败", summary.result.ToString(), "OK"); + } + } + + // [MenuItem(JPMenuName.BUILD_RELEASE_IPA)] + public static void BuildRelease() + { + BuildSummary summary = Export(BuildType_Release); + + if (summary.result == BuildResult.Succeeded) + { + RunBuildIpaShell(); + } + else + { + EditorUtility.DisplayDialog("Xcode 工程导出失败", summary.result.ToString(), "OK"); + } + } + + [MenuItem(JPMenuName.BUILD_RELEASE_XCODE)] + public static void ExportXcodeRelease() + { + ExportToXcode(BuildType_Release); + } + + [MenuItem(JPMenuName.BUILD_DEBUG_XCODE)] + public static void ExportXcodeDebug() + { + ExportToXcode(BuildType_Debug); + } + + private static void ExportToXcode(string buildType) + { + BuildSummary summary = Export(buildType); + if (summary.result == BuildResult.Succeeded) + { + var exportDir = $"导出路径为 = {XcodeDir}"; + bool isOk = EditorUtility.DisplayDialog("Xcode 工程导出成功,是否打开目录?", + exportDir, + "Open", + "Cancel"); + if (isOk) + { + EditorUtility.RevealInFinder(XcodeDir); + } + } + else + { + EditorUtility.DisplayDialog("Xcode 工程导出失败", summary.result.ToString(), "OK"); + } + } + + + // 导出Xcode + private static BuildSummary Export(string buildType) + { + CurrentBuildType = buildType; + + DirPrepare(); + + var isDebug = buildType == BuildType_Debug; + var buildPlayerOptions = default(BuildPlayerOptions); + buildPlayerOptions.scenes = GetBuildScenes(); + buildPlayerOptions.locationPathName = XcodeDir; + buildPlayerOptions.targetGroup = BuildTargetGroup.iOS; + buildPlayerOptions.target = BuildTarget.iOS; + + buildPlayerOptions.options = + isDebug ? (BuildOptions.Development | BuildOptions.ConnectWithProfiler) : BuildOptions.None; + + var buildReport = BuildPipeline.BuildPlayer(buildPlayerOptions); + var summary = buildReport.summary; + if (summary.result == BuildResult.Succeeded) + { + Debug.Log("Export Xcode Project successes : " + (summary.totalSize / 1024 / 1024) + "M"); + // WriteExportOptionsToPlist(); + } + else if (summary.result == BuildResult.Failed) + { + Debug.LogError("Export Xcode Project failed : " + summary.totalErrors); + } + else if (summary.result == BuildResult.Cancelled) + { + Debug.Log("Export Xcode Project cancelled"); + } + else if (summary.result == BuildResult.Unknown) + { + Debug.Log("Export Xcode Project Unknown..."); + } + + return summary; + } + + // 构建ipa + // private static void BuildIPA() + // { + // + // } + // 目录准备 + private static void DirPrepare() + { + // 如果存在此目录则直接删除 + var xcodeProjectDir = new DirectoryInfo(XcodeDir); + if (xcodeProjectDir.Exists) + { + xcodeProjectDir.Delete(true); + } + + // 信息准备目录创建 + var prepareInfoDir = new DirectoryInfo(iOSPrepareInfoPath); + if (!prepareInfoDir.Exists) + { + Directory.CreateDirectory(iOSPrepareInfoPath); + } + + // 构建结果目录 + var productsDir = new DirectoryInfo(iOSProductsPath); + if (productsDir.Exists) + { + productsDir.Delete(true); + } + + Directory.CreateDirectory(iOSProductsPath); + } + + // // 写入导出ipa所需要的参数信息 + // private static void WriteExportOptionsToPlist() + // { + // var bundleId = AutomationManager.JoyPacBuildParams.iOS_BundleId; + // if (string.IsNullOrEmpty(bundleId)) + // { + // bundleId = Application.identifier; + // } + // + // if (string.IsNullOrEmpty(bundleId)) + // { + // throw new ArgumentException("Please Write ios Bundle Id To JoyPacBuildParams Inspector..."); + // } + // + // var mobileProVisionName = AutomationManager.JoyPacBuildParams.iOS_MobileProVisionName; + // + // if (string.IsNullOrEmpty(mobileProVisionName)) + // { + // throw new ArgumentException( + // "Please Write ios mobileProVisionName To JoyPacBuildParams Inspector..."); + // } + // + // // + // if (!File.Exists(ExportOptionsInfoPath)) { + // + // return; + // } + // + // var doc = new PlistDocument(); + // var root = doc.root; + // var plistElementDict = root.CreateDict("provisioningProfiles"); + // plistElementDict.SetString(bundleId, mobileProVisionName); + // + // if (JPPackageManager.HasComponent(JPComponenetType.Push)) + // { + // var pushBundleId = AutomationManager.JoyPacBuildParams.iOS_BundleId + ".NotificationExtension"; + // var pushProfileName = AutomationManager.JoyPacBuildParams.iOS_Push_Extension_ProVisionName; + // plistElementDict.SetString(pushBundleId, pushProfileName); + // } + // + // doc.WriteToFile(ExportOptionsInfoPath); + // Debug.Log("export options 写入plist文件成功"); + // } + + // 运行构建ipa的路径 + private static void RunBuildIpaShell() + { + + Debug.Log("开始执行shell脚本导出ipa"); + Debug.Log("BuildIpaScriptPath : " + BuildIpaScriptPath); + Debug.Log("CurrentBuildType : " + CurrentBuildType); + Debug.Log("XcodeDir : " + XcodeDir); + + var command = BuildIpaScriptPath + " " + CurrentBuildType + " " + XcodeDir; + ExecuteCommandScript(command); + } + + // 执行shell 命令 + private static void ExecuteCommandScript(string command) + { + try + { + using (Process myProcess = new Process()) + { + myProcess.StartInfo.FileName = "bash"; + myProcess.StartInfo.UseShellExecute = false; + myProcess.StartInfo.CreateNoWindow = true; + myProcess.StartInfo.Arguments = command; + myProcess.Start(); + EditorUtility.DisplayProgressBar("Build IPA", "正在执行编译脚本导出ipa,请耐心等待....", 0.5f); + myProcess.WaitForExit(); + EditorUtility.ClearProgressBar(); + if (myProcess.ExitCode == 0) + { + //脚本执行正常 + bool isOpen = EditorUtility.DisplayDialog("IPA导出成功", $"导出路径为:{iOSProductsPath}", "open", "cancel"); + if (isOpen) + { + EditorUtility.RevealInFinder(iOSProductsPath + "/Archive"); + } + } + else + { + EditorUtility.DisplayDialog("IPA导出失败", "导出失败", "ok"); + } + myProcess.Close(); + } + } + catch (Exception e) + { + Debug.LogError(e.Message); + } + } + + // 找出所有需要构建的场景 + private static string[] GetBuildScenes() + { + var names = new List(); + foreach (var settingsScene in EditorBuildSettings.scenes) + { + if (settingsScene == null) + { + continue; + } + + if (settingsScene.enabled) + { + names.Add(settingsScene.path); + } + } + return names.ToArray(); + } +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/BuildIpa.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/BuildIpa.cs.meta new file mode 100644 index 00000000..e14409b9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/BuildIpa.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: cfc33c0536c04b2c932668157a96a18a +timeCreated: 1615530203 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/ShellUtil.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/ShellUtil.cs new file mode 100644 index 00000000..e3a4d487 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/ShellUtil.cs @@ -0,0 +1,164 @@ + + + public static class ShellUtil + { + public static string GetApmShell(string appId) + { + return + "#!/bin/sh\n" + + "################################################################################\n" + + "# 自定义配置\n" + + "###############################################################################\n" + + "# Debug模式编译是否上传,1=上传 0=不上传,默认不上传\n" + + "UPLOAD_DEBUG_SYMBOLS=0\n" + + "\n" + + "# 模拟器编译是否上传,1=上传,0=不上传,默认不上传\n" + + "UPLOAD_SIMULATOR_SYMBOLS=0\n" + + "\n" + + "# APMInsightID:应用云 ID\n" + + $"APMInsight_APP_ID=\"{appId}\"\n" + + "\n" + + "################################################################################\n" + + "# 注意: 如果你不知道此脚本的执行流程和用法,请不要随便修改!\n" + + "################################################################################\n" + + "\n" + + "DSYM_UPLOAD_URL=\"https://datarangers.com.cn/perfguard/api/guest/app/mapping/upload\"\n" + + "\n" + + "if [[ $APMInsight_APP_ID == \"XXX\" ]]; then\n" + + " if [[ $1 ]]; then\n" + + " echo \"APPID: $1\"\n" + + " APMInsight_APP_ID=$1\n" + + " else\n" + + " echo \"No arguments, pass your APMInsightID as the first argument or modify 'APMInsight_APP_ID' in the script.\"\n" + + " exit 0\n" + + " fi\n" + + "fi\n" + + "\n" + + "function main() {\n" + + " # 退出执行并打印提示信息\n" + + " warningWithMessage() {\n" + + " echo \"--------------------------------\"\n" + + " echo -e \"${1}\"\n" + + " echo \"--------------------------------\"\n" + + " echo \"No upload and over.\"\n" + + " echo \"----------------------------------------------------------------\"\n" + + " UPLOADFLAG=0\n" + + " exit ${2}\n" + + " }\n" + + " \n" + + " UPLOADFLAG=1\n" + + " \n" + + " echo \"Uploading dSYM to APMInsight.\"\n" + + " \n" + + " echo \"--------------------------------\"\n" + + " echo \"Step 1: Prepare application information.\"\n" + + " echo \"--------------------------------\"\n" + + " \n" + + " echo \"Product Name: ${PRODUCT_NAME}\"\n" + + " echo \"APMInsight App ID: ${APMInsight_APP_ID}\"\n" + + " \n" + + " echo \"--------------------------------\"\n" + + " echo \"Step 2: Check the arguments ...\"\n" + + " echo \"--------------------------------\"\n" + + " \n" + + " ##检查模拟器是否允许上传符号\n" + + " if [ \"$EFFECTIVE_PLATFORM_NAME\" == \"-iphonesimulator\" ]; then\n" + + " if [[ $UPLOAD_SIMULATOR_SYMBOLS -eq 0 ]]; then\n" + + " warningWithMessage \"Warning: Build for simulator and skipping to upload. \n" + + "You can modify 'UPLOAD_SIMULATOR_SYMBOLS' to 1 in the script.\" 0\n" + + " fi\n" + + " fi\n" + + " \n" + + " # 检查DEBUG模式是否允许上传符号\n" + + " if [[ ${CONFIGURATION=} == Debug* ]]; then\n" + + " if [[ $UPLOAD_DEBUG_SYMBOLS -eq 0 ]]; then\n" + + " warningWithMessage \"Warning: Build for debug mode and skipping to upload. \n" + + "You can modify 'UPLOAD_DEBUG_SYMBOLS' to 1 in the script.\" 0\n" + + " fi\n" + + " fi\n" + + " \n" + + " # 检查必须参数是否设置\n" + + " if [ ! \"${APMInsight_APP_ID}\" ]; then\n" + + " warningWithMessage \"Error: APMInsight App ID not defined.\" 1\n" + + " fi\n" + + " \n" + + " function uploadDSYM() {\n" + + " DSYM_SRC=\"$1\"\n" + + " if [ ! -d \"$DSYM_SRC\" ]; then\n" + + " warningWithMessage \"dSYM source not found: ${DSYM_SRC}\" 1\n" + + " fi\n" + + " \n" + + " APPID=\"${APMInsight_APP_ID}\"\n" + + " \n" + + " ZIP_DIR_PATH=$(dirname ${DSYM_SRC})\n" + + " FILENAME=$(basename ${DSYM_SRC})\n" + + " DSYM_SYMBOL_OUT_ZIP_NAME=\"APMInsight_dSYM_${APPID}.zip\"\n" + + " DSYM_ZIP_FPATH=\"${ZIP_DIR_PATH}/${DSYM_SYMBOL_OUT_ZIP_NAME}\"\n" + + " cd \"${ZIP_DIR_PATH}\"\n" + + " PAD=$(zip -r ${DSYM_SYMBOL_OUT_ZIP_NAME} ${FILENAME})\n" + + " \n" + + " if [ ! -e \"${DSYM_ZIP_FPATH}\" ]; then\n" + + " warningWithMessage \"no dSYM zip archive generated: ${DSYM_ZIP_FPATH}\" 1\n" + + " fi\n" + + " \n" + + " FILESIZE=$(/usr/bin/stat -f%z ${DSYM_ZIP_FPATH})\n" + + " echo \"dsym size: ${FILESIZE} bytes\"\n" + + " \n" + + " echo \"--------------------------------\"\n" + + " echo \"Step 3: Upload the zipped dSYM file.\"\n" + + " echo \"--------------------------------\"\n" + + " MD5ZIP=$(md5 -q ${DSYM_ZIP_FPATH})\n" + + " if [ ! ${#MD5ZIP} -eq 32 ]; then\n" + + " warningWithMessage \"Error: Failed to caculate md5 of zipped file.\" 1\n" + + " fi\n" + + " echo \"zip md5 : ${MD5ZIP}\"\n" + + " echo \"signature : ${MD5ZIP}\"\n" + + " \n" + + " echo \"dSYM upload url: ${DSYM_UPLOAD_URL}\"\n" + + " \n" + + " # Upload dSYM to APMInsight\n" + + " echo \"curl ${DSYM_UPLOAD_URL} -F \\\"file=@${DSYM_ZIP_FPATH}\\\" -F \\\"aid=${APMInsight_APP_ID}\\\" -H \\\"Content-Type: multipart/form-data\\\" -w %{http_code} -v \"\n" + + " \n" + + " echo \"--------------------------------\"\n" + + " \n" + + " # 上传请求\n" + + " STATUS=$(curl ${DSYM_UPLOAD_URL} -F \"file=@${DSYM_ZIP_FPATH}\" -F \"type=Dwarf\" -F \"os=iOS\" -F \"aid=${APMInsight_APP_ID}\" -H \"Content-Type: multipart/form-data\" -w %{http_code} -v)\n" + + " \n" + + " echo \"APMInsight server response: ${STATUS}\"\n" + + "\n" + + " if [ ${STATUS} = \"{\\\"err_detail\\\":\\\"\\\",\\\"data\\\":null,\\\"error_msg\\\":\\\"\\\",\\\"error_no\\\":0}200\" ]; then" + + " echo \"Upload dSYM successfully! Delete ${DSYM_SYMBOL_OUT_ZIP_NAME}.\"\n" + + " if [ -f ${DSYM_SYMBOL_OUT_ZIP_NAME} ]; then\n" + + " rm ${DSYM_SYMBOL_OUT_ZIP_NAME}\n" + + " fi\n" + + " else\n" + + " echo \"Failed to upload dSYM. Try to upload the file at path ${DSYM_SYMBOL_OUT_ZIP_NAME} manually.\"\n" + + " fi\n" + + " }\n" + + " \n" + + " # .dSYM文件信息\n" + + " echo \"DSYM FOLDER ${DWARF_DSYM_FOLDER_PATH}\"\n" + + " \n" + + " DSYM_FOLDER=\"${DWARF_DSYM_FOLDER_PATH}\"\n" + + " \n" + + " for i in {1..10};\n" + + " do\n" + + " sleep 1s\n" + + " # 遍历目录查找当前工程名的文件\n" + + " for dsymFile in $(find \"$DSYM_FOLDER\" -name \"${PRODUCT_NAME}.*.dSYM\"); \n" + + " do\n" + + " # 判断压缩文件的源文件是否存在\n" + + " DSYM_SINGLE_FILE_NAME=\"${dsymFile}/Contents/Resources/DWARF/${PRODUCT_NAME}\"\n" + + " if [ ${UPLOADFLAG} -eq 1 -a -s \"${DSYM_SINGLE_FILE_NAME}\" ]; then\n" + + " echo \"Found dSYM file: $dsymFile\"\n" + + " uploadDSYM $dsymFile\n" + + " break 2\n" + + " fi\n" + + " done\n" + + " done\n" + + "}\n" + + " \n" + + "main\n" + + "\n"; + } + } diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/ShellUtil.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/ShellUtil.cs.meta new file mode 100644 index 00000000..33f2dfe9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/ShellUtil.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 76a2fec145724291b50c5d2f9108dc9d +timeCreated: 1621516898 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa.sh b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa.sh new file mode 100644 index 00000000..8ffa6deb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa.sh @@ -0,0 +1,55 @@ +#!/bin/sh + +# 构建类型,Release 或 Debug +BuildType=$1 + +# 打印日志方法 +# shellcheck disable=SC2112 +function PrintLog() { + echo "============== $1 ==============" +} + +# 检查是否传入了参数,如果传未传入参数则赋予默认值为Release +if [ ! "$1" ]; then + PrintLog "BuildType is null,default release" + BuildType="Release" +else + PrintLog "BuildType is "${BuildType} +fi + +# 当前脚本所在路径 +CurrentScriptPath=$(dirname "$0") + +# 当前脚本所在的绝对路径 +CurrentScriptRelativePath=Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS + +# project path +# shellcheck disable=SC2039 +PROJ_PATH=${CurrentScriptPath//${CurrentScriptRelativePath}//""} + +# 去掉项目路径中最后一个字符"/" +PROJ_PATH=${PROJ_PATH%?} + +# unity app path +UNITY_PATH=/Applications/Unity/Hub/Editor/2019.4.19f1/Unity.app/Contents/MacOS/Unity + +# 构建日志的输出路径 +LOG_PATH=$PROJ_PATH/BuildProductDir/iOS/Log/BuildIpa.log + +# log日志输出目录 +PrintLog "LOG_PATH = "${LOG_PATH} + +PrintLog "Unity Export XcodeProject Begin" + +if [ ${BuildType} = "Release" ]; then + # 构建release ipa + PrintLog "Execute ExportXcodeProject.BuildRelease" + $UNITY_PATH -projectPath $PROJ_PATH -executeMethod ByteDance.Union.BuildIpa.BuildRelease -logFile $LOG_PATH -batchMode -quit +else + # 构建debug ipa + PrintLog "Execute ExportXcodeProject.BuildDebug" + $UNITY_PATH -projectPath $PROJ_PATH -executeMethod ByteDance.Union.BuildIpa.BuildDebug -logFile $LOG_PATH -batchMode -quit +fi + +PrintLog "Unity Export XcodeProject Finish" +PrintLog "Prepare Build Ipa..." diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa.sh.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa.sh.meta new file mode 100644 index 00000000..1ccf6855 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa.sh.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 22148540dde2144a192fc86c43f58141 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa_from_xcode_project.sh b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa_from_xcode_project.sh new file mode 100644 index 00000000..91e7bfa7 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa_from_xcode_project.sh @@ -0,0 +1,48 @@ +#!/bin/sh + +#构建类型、Debug或Release,外部传入的第一个参数 +BuildType=$1 + +echo "${BuildType}" + +#xcode工程路径,外部传入的第二个参数 +XcodeProjectPath=$2 + +echo "${XcodeProjectPath}" + +# 切换到当前目xcode项目目录 +# shellcheck disable=SC2164 +cd "${XcodeProjectPath}" + +#工程名字 +ProjectName="Unity-iPhone" + +# 构建产物路径 +ProductsPath=$(dirname "$PWD")/Products + +echo ProductsPath="${ProductsPath}" + +# Archive路径 +ArchivePath=${ProductsPath}/Archive/${ProjectName}".xcarchive" + +# 导出ipa所需要的配置文件 +ExportOptionsPath=$(dirname "$PWD")/PrepareInfo/ExportOptions.plist + +#编译工程 +xcodebuild archive -scheme ${ProjectName} -configuration "${BuildType}" -archivePath "${ArchivePath}" -quiet || exit + +# 从archive中导出ipa +xcodebuild \ + '#从archive中导出ipa' \ + -exportArchive -archivePath "${ArchivePath}" \ + '#构建类型,Debug或Release' \ + -configuration "${BuildType}" \ + '#archive存在的路径' \ + -exportArchive "${ArchivePath}" \ + '#导出Ipa需要的配置文件exportOptions.plist,此文件很重要' \ + -exportOptionsPlist "${ExportOptionsPath}" \ + '#导出ipa所在的位置' \ + -exportPath "${ProductsPath}" \ + -quiet || exit + +exit 0 diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa_from_xcode_project.sh.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa_from_xcode_project.sh.meta new file mode 100644 index 00000000..b0f2bbf8 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/export_ipa_from_xcode_project.sh.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: bdb9451d3016149b3a4c6171f3ecf0cb +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/iOSPlatformPostProcess.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/iOSPlatformPostProcess.cs new file mode 100644 index 00000000..8c624f02 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/iOSPlatformPostProcess.cs @@ -0,0 +1,197 @@ +#if UNITY_EDITOR && UNITY_IOS +using System.IO; +using UnityEngine; +using UnityEditor; +using UnityEditor.Callbacks; +using UnityEditor.iOS.Xcode; +using UnityEditor.iOS.Xcode.Extensions; +using System; + +internal static class iOSPlatformPostProcess +{ + [PostProcessBuild(999)] + private static void OnPostProcessBuild(BuildTarget target, string pathToBuiltProject) + { + if (target != BuildTarget.iOS) + { + return; + } + + var projPath = PBXProject.GetPBXProjectPath(pathToBuiltProject); + var proj = new PBXProject(); + proj.ReadFromString(File.ReadAllText(projPath)); + + + + Debug.Log("pathToBuiltProject" + pathToBuiltProject); + //att弹框 + EditorAtt(pathToBuiltProject); + ///添加bundle + ChangeBundleFile(proj); + + // proj.WriteToFile(projPath); + UpdatePlistInfo(pathToBuiltProject); + + //info.plist + CopyInfoPlist(proj, pathToBuiltProject); + + //framework + EmbedFramework(proj); + File.WriteAllText(projPath, proj.WriteToString()); + } + + private static void ChangeBundleFile(PBXProject proj) + { +#if UNITY_2019_3_OR_NEWER + + string targetMainGUID = proj.GetUnityMainTargetGuid(); + + string target = proj.GetUnityFrameworkTargetGuid(); + // 2019.3版本以后需要手动添加.bundle到UnityMainTarget + string[] relativeAssetsBundlePaths = JoyPacParamsManager.WriteBundlePath(); + + foreach (var bundlePath in relativeAssetsBundlePaths) + { + string guid = proj.FindFileGuidByProjectPath($"Frameworks/{bundlePath}"); + + if (!string.IsNullOrEmpty(guid)) + { + proj.RemoveFileFromBuild(target, guid); + proj.AddFileToBuild(targetMainGUID, guid); + Debug.Log("add bundle: " + ($"Frameworks/{bundlePath}") + " Succeeded"); + } + else + { + Debug.LogError("add bundle: " + ($"Frameworks/{bundlePath}") + " failed"); + } + } +#endif + + + } + + + private static void EmbedFramework(PBXProject proj) + { + string[] relativeAssetsEmbedFrameworksPaths = JoyPacParamsManager.EmbedFrameworks(); +#if UNITY_2019_3_OR_NEWER + + string targetMain = proj.GetUnityMainTargetGuid(); +#else + string targetMain = proj.TargetGuidByName("Unity-iPhone"); +#endif + foreach (var bundlePath in relativeAssetsEmbedFrameworksPaths) + { + string guid = proj.FindFileGuidByProjectPath($"Frameworks/{bundlePath}"); + + if (!string.IsNullOrEmpty(guid)) + { + + PBXProjectExtensions.AddFileToEmbedFrameworks(proj, targetMain, guid); + Debug.Log("add EmbedFramework: " + ($"Frameworks/{bundlePath}") + " Succeeded"); + } + else + { + Debug.LogError("add EmbedFramework: " + ($"Frameworks/{bundlePath}") + " failed"); + } + } + } + + private static void CopyInfoPlist(PBXProject proj, string _path) + { + if (!JPPackageManager.HasComponent(JPComponenetType.JoyPacAd)) + return; + + + JPReleaseAreaType adinfo = JoyPacParamsManager.GetJPReleaseAreaType(); + string sourcePath = Application.dataPath + "/" + JPService.info_target_path + "/info/" + adinfo + "/" + JPService.info_plist_name; + string targetPath = Application.dataPath + "/Plugin/iOS/" + JPService.info_plist_name; + if (!File.Exists(sourcePath)) + { + Debug.LogError(sourcePath + "为空,请检查是否已放入" + JPService.info_plist_name + "文件"); + Debug.LogError("因检测不到" + JPService.info_plist_name + "文件,所以开始执行删除Xcode工程命令"); + DeletePath(_path); + + } +#if UNITY_2019_3_OR_NEWER + string target = proj.GetUnityMainTargetGuid(); +#else + string target = proj.TargetGuidByName("Unity-iPhone"); +#endif + + File.Copy(sourcePath, Path.Combine(_path, JPService.info_plist_name)); + proj.AddFileToBuild(target, proj.AddFile(JPService.info_plist_name, JPService.info_plist_name, PBXSourceTree.Source)); + + + + } + + + /// + /// 删除指定目录下的文件以及文件夹 + /// + /// + public static void DeletePath(string path) + { + if (Directory.Exists(path)) + { + DirectoryInfo info = new DirectoryInfo(path); + FileSystemInfo[] arrInfo = info.GetFileSystemInfos(); + for (int i = 0; i < arrInfo.Length; ++i) + { + if (arrInfo[i].Attributes == FileAttributes.Directory) + { + Directory.Delete(arrInfo[i].ToString(), true); + } + else + { + File.Delete(arrInfo[i].ToString()); + } + } + } + } + + //update info.plist + private static void UpdatePlistInfo(string projPath) + { + /* info.plist */ + var plistPath = Path.Combine(projPath, "Info.plist"); + var plist = new PlistDocument(); + plist.ReadFromFile(plistPath); + //admob的apppid , + //目前无applovin + JoyPacParamsManager.WriteInitParamsToXcodePlist(plist); + + File.WriteAllText(plistPath, plist.WriteToString()); + + + + + } + + static void EditorAtt(string _path) + { + + //有广告或者不需要att时 + if (JoyPacParamsManager.isHasComponentJoyPacAd() || !JoyPacParamsManager.isAttEnable()) + return; + JoypacStaticClassHelper UnityAppController = new JoypacStaticClassHelper(_path + "/Classes/UnityAppController.mm"); + UnityAppController.WriteBelow("#import \"UnityAppController.h\"", "\n#import "); + + string attCode = +"if (@available(iOS 14.0, *)){" + +"\r[ATTrackingManager requestTrackingAuthorizationWithCompletionHandler: ^(ATTrackingManagerAuthorizationStatus status) {" + + "\r dispatch_async(dispatch_get_main_queue(), ^{" + + + "\r UnityPause(0);" + + "\r });" + + "\r }];" + + "\r }\n"; + + UnityAppController.WriteBelow("[KeyboardDelegate Initialize];\n", attCode); + } + + +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/iOSPlatformPostProcess.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/iOSPlatformPostProcess.cs.meta new file mode 100644 index 00000000..9f2f9078 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/Editor_iOS/iOSPlatformPostProcess.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a329cfca07c8f4c9f8b7a49d1803ce48 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/UnitypackageManager.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/UnitypackageManager.cs new file mode 100644 index 00000000..4cf5e192 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/UnitypackageManager.cs @@ -0,0 +1,102 @@ +using System; +using System.IO; +using System.Xml; +using System.Collections; +using System.Collections.Generic; +using System.Diagnostics; +using System.Text.RegularExpressions; +using UnityEngine; +using UnityEditor; +using UnityEditor.Callbacks; +public class NewMonoBehaviour : MonoBehaviour +{ + + // SDK根目录 + private const string JoyPacSDK = "Assets/JoyPacSDK"; + private const string Examples = "Assets/Examples"; + private const string I2 = "Assets/I2"; + private const string Joypac = "Assets/Joypac"; + private const string JPChannel = "Assets/JPChannel"; + private const string Other = "Assets/Other"; + private const string Plugins = "Assets/Plugins"; + private const string Resources = "Assets/Resources"; + + + // 导出最终包的unity package前缀. + private const string SdkNamePreFix = "JoyPac_SDK"; + + + // [MenuItem("Assets/Adjust/Export Unity Package")] + public static void ExportAdjustUnityPackage() + { + + List assetsToExport = new List(); + + // Adjust Assets. + assetsToExport.Add(Examples + "/Scenes/DemoScene.unity"); + + + assetsToExport.Add(Examples + "/Scripts/BannerButton.cs"); + // assetsToExport.Add(assetsPath + "/Android/AdjustAndroid.cs"); + // assetsToExport.Add(assetsPath + "/Android/AdjustAndroidManifest.xml"); + + // assetsToExport.Add(assetsPath + "/Editor/AdjustEditor.cs"); + // assetsToExport.Add(assetsPath + "/Editor/AdjustSettings.cs"); + + // assetsToExport.Add(assetsPath + "/ExampleGUI/ExampleGUI.cs"); + // assetsToExport.Add(assetsPath + "/ExampleGUI/ExampleGUI.prefab"); + // assetsToExport.Add(assetsPath + "/ExampleGUI/ExampleGUI.unity"); + + // assetsToExport.Add(assetsPath + "/iOS/ADJAttribution.h"); + // assetsToExport.Add(assetsPath + "/iOS/ADJConfig.h"); + // assetsToExport.Add(assetsPath + "/iOS/ADJEvent.h"); + // assetsToExport.Add(assetsPath + "/iOS/ADJEventFailure.h"); + // assetsToExport.Add(assetsPath + "/iOS/ADJEventSuccess.h"); + // assetsToExport.Add(assetsPath + "/iOS/ADJLogger.h"); + // assetsToExport.Add(assetsPath + "/iOS/ADJSessionFailure.h"); + // assetsToExport.Add(assetsPath + "/iOS/ADJSessionSuccess.h"); + // assetsToExport.Add(assetsPath + "/iOS/ADJSubscription.h"); + // assetsToExport.Add(assetsPath + "/iOS/Adjust.h"); + // assetsToExport.Add(assetsPath + "/iOS/AdjustiOS.cs"); + // assetsToExport.Add(assetsPath + "/iOS/AdjustSdk.a"); + // assetsToExport.Add(assetsPath + "/iOS/AdjustUnity.h"); + // assetsToExport.Add(assetsPath + "/iOS/AdjustUnity.mm"); + // assetsToExport.Add(assetsPath + "/iOS/AdjustUnityDelegate.h"); + // assetsToExport.Add(assetsPath + "/iOS/AdjustUnityDelegate.mm"); + + // assetsToExport.Add(assetsPath + "/Prefab/Adjust.prefab"); + + // assetsToExport.Add(assetsPath + "/Unity/Adjust.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustAppStoreSubscription.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustAttribution.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustConfig.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustEnvironment.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustEvent.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustEventFailure.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustEventSuccess.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustLogLevel.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustPlayStoreSubscription.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustSessionFailure.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustSessionSuccess.cs"); + // assetsToExport.Add(assetsPath + "/Unity/AdjustUtils.cs"); + + // assetsToExport.Add(assetsPath + "/Windows/AdjustWindows.cs"); + // assetsToExport.Add(assetsPath + "/Windows/WindowsPcl.dll"); + // assetsToExport.Add(assetsPath + "/Windows/WindowsUap.dll"); + // assetsToExport.Add(assetsPath + "/Windows/Stubs/Win10Interface.dll"); + // assetsToExport.Add(assetsPath + "/Windows/Stubs/Win81Interface.dll"); + // assetsToExport.Add(assetsPath + "/Windows/Stubs/WinWsInterface.dll"); + // assetsToExport.Add(assetsPath + "/Windows/W81/AdjustWP81.dll"); + // assetsToExport.Add(assetsPath + "/Windows/W81/Win81Interface.dll"); + // assetsToExport.Add(assetsPath + "/Windows/WS/AdjustWS.dll"); + // assetsToExport.Add(assetsPath + "/Windows/WS/WinWsInterface.dll"); + // assetsToExport.Add(assetsPath + "/Windows/WU10/AdjustUAP10.dll"); + // assetsToExport.Add(assetsPath + "/Windows/WU10/Win10Interface.dll"); + // assetsToExport.Add(assetsPath + "/Windows/Newtonsoft.Json.dll"); + + // AssetDatabase.ExportPackage( + // assetsToExport.ToArray(), + // exportedFileName, + // ExportPackageOptions.IncludeDependencies | ExportPackageOptions.Interactive); + } +} diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/UnitypackageManager.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/UnitypackageManager.cs.meta new file mode 100644 index 00000000..9240d360 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Build/UnitypackageManager.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 9600e7a7ec6014d518aadd1820890d16 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/EditorUserBuildSettings.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/EditorUserBuildSettings.cs new file mode 100644 index 00000000..85eb0931 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/EditorUserBuildSettings.cs @@ -0,0 +1,32 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEditor; +using UnityEngine; + +public class UserBuildSettings : MonoBehaviour +{ + [System.Obsolete] + static UserBuildSettings() + { + EditorUserBuildSettings.activeBuildTargetChanged += OnChangePlatform; + } + static void OnChangePlatform() + { + Debug.Log("Has Pro Licence : " + Application.HasProLicense()); + Debug.Log("Platform : " + EditorUserBuildSettings.activeBuildTarget); + if (EditorUserBuildSettings.activeBuildTarget == BuildTarget.iOS) + { + string str = PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android); + Debug.Log("old " + str); + str = str.Replace("ANDROID_GP", null); + + PlayerSettings.SetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android, + "ANDROID_GP" + ";" + str); + Debug.Log("new " + PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android)); + + + Debug.Log("当前平台为iOS"); + } + } + +} diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/EditorUserBuildSettings.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/EditorUserBuildSettings.cs.meta new file mode 100644 index 00000000..b82ebee6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/EditorUserBuildSettings.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: df75b06f7f5284959914c0dbd7575446 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector.meta new file mode 100644 index 00000000..1bd877ae --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: bebd8773399c41318a297d7d4e627aa8 +timeCreated: 1615294232 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/BaseParamsInspector.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/BaseParamsInspector.cs new file mode 100644 index 00000000..0df3d848 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/BaseParamsInspector.cs @@ -0,0 +1,280 @@ +using System; +using System.Reflection; +using UnityEditor; +using UnityEngine; + +#if UNITY_EDITOR + +public abstract class BaseParamsInspector : Editor + where T : class +{ + // 通用标签间的间距 + private const float COMMON_SPACE = 13f; + + // 最大间距 + private const float MAX_SPACE = 25f; + + // 目标对象 + protected T mTargetObject; + + // 字段值改变 + protected Action FieldValueChangeListener; + + /// + /// 绘制参数面板. + /// + protected abstract void DrawInspector(); + + /// + /// 系统会回调此方法. + /// + public override void OnInspectorGUI() + { + this.mTargetObject = this.target as T; + + // 绘制整体带边框UI + this.BeginDrawVerticalBox(); + + // 交给子类去绘制 + this.DrawInspector(); + + // 整体边框绘制结束 + this.EndDrawVerticalBox(); + } + + /// + /// 开始绘制垂直方向Box. + /// + protected void BeginDrawVerticalBox() + { + EditorGUILayout.BeginVertical("Box", GUILayout.ExpandWidth(true)); + } + + /// + /// 结束绘制垂直方向Box. + /// + protected void EndDrawVerticalBox() + { + EditorGUILayout.EndVertical(); + } + + + // 绘制1级标题 + protected void DrawH1Title(string title) + { + DrawAreaTitle(title, Color.red, TextAnchor.MiddleCenter, 20); + } + + // 绘制2级标题 + protected void DrawH2Title(string title) + { + DrawAreaTitle(title, new Color(128, 138, 135), TextAnchor.MiddleCenter, 16); + } + + // 绘制3级标题 + protected void DrawH3Title(string title) + { + DrawAreaTitle(title, GetTitleColor(), TextAnchor.MiddleCenter, 16); + } + + // 获取当前标题颜色 + private Color GetTitleColor() + { + return JPEditorPrefsHelper.CurrentSkinType == EditorSkinType.Dark ? new Color(128, 138, 135) : Color.black; + } + + /// + /// 绘制标题区域. + /// + /// 标题. + /// 字体颜色. + /// 对齐方式. + /// 字体大小. + private static void DrawAreaTitle(string title, Color color, TextAnchor textAnchor, int fontSize) + { + EditorGUILayout.BeginVertical(); + DrawVerticalSpace(MAX_SPACE); + + var guiStyle = new GUIStyle(); + guiStyle.fontSize = fontSize; + guiStyle.normal.textColor = color; + guiStyle.fontStyle = FontStyle.BoldAndItalic; + guiStyle.alignment = textAnchor; + EditorGUILayout.TextArea(title, guiStyle); + EditorGUILayout.EndVertical(); + DrawVerticalSpace(COMMON_SPACE); + } + + /// + /// 绘制文本框控件. + /// + /// 标签名称. + /// 字段名称. + protected void DrawTextArea(string labelName, string fieldName) + { + // 读取字段中设置的文本 + var text = this.getFieldValue(this.mTargetObject, fieldName) as string; + + var oldText = text; + + EditorGUILayout.BeginHorizontal(); + + // 绘制标签名称 + EditorGUILayout.LabelField(new GUIContent(labelName)); + + // 监听文本改变,同时设置到目标对象中 + EditorGUI.BeginChangeCheck(); + text = EditorGUILayout.DelayedTextField(text); + var change = EditorGUI.EndChangeCheck() && text != oldText; + if (change) + { + this.NotifyFeildValueChange(fieldName, text); + } + + // 绘制结束标记 + EditorGUILayout.EndHorizontal(); + DrawVerticalSpace(COMMON_SPACE); + } + + /// + /// 绘制label + /// + /// + /// + protected void DrawLabel(string title, string content, string tip) + { + if (!string.IsNullOrEmpty(tip)) + EditorGUILayout.HelpBox(tip, MessageType.Info); + + EditorGUILayout.BeginHorizontal(); + EditorGUILayout.PrefixLabel(title); + GUILayoutOption option = GUILayout.Height(MAX_SPACE); + EditorGUILayout.SelectableLabel(content, option); + EditorGUILayout.EndHorizontal(); + DrawVerticalSpace(COMMON_SPACE); + } + + /// + /// 绘制开关类型控件. + /// + /// 标签名称. + /// 字段名称. + protected void DrawToggle( + string labelName, string fieldName) + { + var value = (bool)this.getFieldValue(this.mTargetObject, fieldName); + var oldValue = value; + + EditorGUILayout.BeginHorizontal(); + + // 监听开关状态改变,同时设置到目标对象中 + EditorGUI.BeginChangeCheck(); + + value = EditorGUILayout.Toggle(new GUIContent(labelName), value); + var change = EditorGUI.EndChangeCheck() && oldValue != value; + if (change) + { + this.NotifyFeildValueChange(fieldName, value); + } + + EditorGUILayout.EndHorizontal(); + DrawVerticalSpace(COMMON_SPACE); + } + + + /// + /// 绘制枚举类型选择框. + /// + /// 标签名称. + /// 字段名称. + protected void DrawEnumPopup(string labelName, string fieldName) + { + var value = (Enum)this.getFieldValue(this.mTargetObject, fieldName); + + var oldValue = value; + + EditorGUILayout.BeginHorizontal(); + + EditorGUI.BeginChangeCheck(); + + value = EditorGUILayout.EnumPopup(labelName, value); + + var change = EditorGUI.EndChangeCheck() && !Equals(value, oldValue); + + if (change) + { + this.NotifyFeildValueChange(fieldName, value); + } + + EditorGUILayout.EndHorizontal(); + DrawVerticalSpace(COMMON_SPACE); + } + + /// + /// 绘制垂直方向间距. + /// + /// 间距. + private static void DrawVerticalSpace(float pixels) + { + GUILayout.Space(pixels); + } + + private void NotifyFeildValueChange(string fieldName, object value) + { + this.FieldValueChangeListener?.Invoke(fieldName, value); + } + + /// + /// 获取字段信息. + /// + /// 目标对象. + /// 字段名称. + /// 字段信息. + protected FieldInfo GetFieldInfo(T t, string fieldName) + { + if (t == null) + { + Debug.LogError("target object is null."); + return null; + } + + if (string.IsNullOrEmpty(fieldName)) + { + Debug.LogError(t.GetType() + " is null."); + return null; + } + + var type = t.GetType(); + var myFieldInfo = type.GetField(fieldName); + return myFieldInfo; + } + + /// + /// 读取对象中字段的值. + /// + /// 目标对象. + /// 字段名称. + /// 字段对应的值. + private object getFieldValue(T t, string fieldName) + { + var fieldInfo = this.GetFieldInfo(t, fieldName); + return fieldInfo != null ? fieldInfo.GetValue(this.mTargetObject) : null; + } + + /// + /// 刷新目标对象中字段的值. + /// + /// 目标对象. + /// 字段名. + /// 字段值. + protected void RefreshFieldValue(T obj, string fieldName, object value) + { + var fieldInfo = this.GetFieldInfo(obj, fieldName); + if (fieldInfo != null) + { + fieldInfo.SetValue(obj, value); + } + } +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/BaseParamsInspector.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/BaseParamsInspector.cs.meta new file mode 100644 index 00000000..d645a44a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/BaseParamsInspector.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 43475b77e9b94cd5b9187e562d82a9cd +timeCreated: 1615184657 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacBuildParamsInspector.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacBuildParamsInspector.cs new file mode 100644 index 00000000..81f46467 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacBuildParamsInspector.cs @@ -0,0 +1,340 @@ +using System; +using System.Collections.Generic; +using System.Reflection; +using UnityEditor; +using UnityEngine; + +[CustomEditor(typeof(JoyPacBuildParams))] +public class JoyPacBuildParamsInspector : BaseParamsInspector +{ + + // 面板中参数绘制 + protected override void DrawInspector() + { + // 注册字段值改变的监听 + this.FieldValueChangeListener = this.FieldValueChange; + + var joyPacBuildParams = this.mTargetObject; + +#if UNITY_IOS + this.DrawiOSBuildParams(joyPacBuildParams); +#elif UNITY_ANDROID + this.DrawAndroidBuildParams(joyPacBuildParams); +#endif + + Button(); + } + + + + // 绘制iOS平台构建参数 + private void DrawiOSBuildParams(JoyPacBuildParams joyPacBuildParams) + { + this.BeginDrawVerticalBox(); + + this.DrawH1Title("iOS Platform Build Params"); + + JPReleaseAreaType releaseAreaType = JoyPacParamsManager.GetJPReleaseAreaType(); + switch (releaseAreaType) + { + case JPReleaseAreaType.Editor: + this.DrawH2Title("请选择CN或者OS,如需切换请选择[JoyPacSDK-参数配置-打开参数面板切换] \n 【 Select CN or OS, \n if you need to switch, please select \n [JoyPacSDK- Parameter configuration - Open parameter ]panel to switch】"); + break; + case JPReleaseAreaType.CN: + this.DrawH2Title("当前为国内平台,如需切换请选择[JoyPacSDK-参数配置-打开参数面板切换] \n 【 The current platform is China, \n if you need to switch, please select \n [JoyPacSDK- Parameter configuration - Open parameter ]panel to switch】"); + break; + case JPReleaseAreaType.OS: + this.DrawH2Title("当前为海外平台,如需切换请选择[JoyPacSDK-参数配置-打开参数面板切换] \n The current platform is no China, \n if you need to switch, please select \n [JoyPacSDK- Parameter configuration - Open parameter ]panel to switch"); + break; + } + var fieldInfos = JoyPacParamsManager.GetBuildParamsFieldInfoByPlatformType(JPEditorPlatformType.iOS, releaseAreaType, JPEditorComponentType.JoyPacSetting); + foreach (var fieldInfo in fieldInfos) + { + + + switch (releaseAreaType) + { + case JPReleaseAreaType.CN: + if (fieldInfo.Name == "iOSCN_DeveloperTeamID") + { + if (joyPacBuildParams.iOSCN_Automaticall_Sign) + this.DrawComponentByFieldInfo(fieldInfo); + } + else + { + this.DrawComponentByFieldInfo(fieldInfo); + } + break; + case JPReleaseAreaType.OS: + if (fieldInfo.Name == "iOSOS_DeveloperTeamID") + { + if (joyPacBuildParams.iOSOS_Automaticall_Sign) + this.DrawComponentByFieldInfo(fieldInfo); + } + + else + { + this.DrawComponentByFieldInfo(fieldInfo); + } + break; + + + } + + } + + this.EndDrawVerticalBox(); + } + + + // 绘制Android平台构建参数 + private void DrawAndroidBuildParams(JoyPacBuildParams joyPacBuildParams) + { + this.BeginDrawVerticalBox(); + + this.DrawH1Title("Android Platform Build Params"); + + JPReleaseAreaType releaseAreaType = JoyPacParamsManager.GetJPReleaseAreaType(); + switch (releaseAreaType) + { + case JPReleaseAreaType.Editor: + this.DrawH2Title("请选择CN或者OS,如需切换请选择[JoyPacSDK-参数配置-打开参数面板切换] \n 【 Select CN or OS, \n if you need to switch, please select \n [JoyPacSDK- Parameter configuration - Open parameter ]panel to switch】"); + break; + case JPReleaseAreaType.CN: + this.DrawH2Title("当前为国内平台,如需切换请选择[JoyPacSDK-参数配置-打开参数面板切换] \n 【 The current platform is China, \n if you need to switch, please select \n [JoyPacSDK- Parameter configuration - Open parameter ]panel to switch】"); + break; + case JPReleaseAreaType.OS: + this.DrawH2Title("当前为海外平台,如需切换请选择[JoyPacSDK-参数配置-打开参数面板切换] \n The current platform is no China, \n if you need to switch, please select \n [JoyPacSDK- Parameter configuration - Open parameter ]panel to switch"); + break; + } + var fieldInfos = JoyPacParamsManager.GetBuildParamsFieldInfoByPlatformType(JPEditorPlatformType.Android, releaseAreaType, JPEditorComponentType.JoyPacSetting); + foreach (var fieldInfo in fieldInfos) + { + + + switch (releaseAreaType) + { + case JPReleaseAreaType.CN: + if (fieldInfo.Name == "iOSCN_DeveloperTeamID") + { + if (joyPacBuildParams.iOSCN_Automaticall_Sign) + this.DrawComponentByFieldInfo(fieldInfo); + } + else + { + this.DrawComponentByFieldInfo(fieldInfo); + } + break; + case JPReleaseAreaType.OS: + if (fieldInfo.Name == "iOSOS_DeveloperTeamID") + { + if (joyPacBuildParams.iOSOS_Automaticall_Sign) + this.DrawComponentByFieldInfo(fieldInfo); + } + + else + { + this.DrawComponentByFieldInfo(fieldInfo); + } + break; + + + } + + } + + this.EndDrawVerticalBox(); + } + + private void Button() + { + if (GUILayout.Button("更新")) + { + bool isAuto_Sign = JoyPacSettingUpDate(); + string con = "Change productName to:" + SettingStringsKey.Instance.productName + + " \n Change bundleVersion to: " + SettingStringsKey.Instance.bundleVersion + + "\n Change BundleID to: " + SettingStringsKey.Instance.BundleID; + + string message = ""; +#if UNITY_IOS + if (isAuto_Sign) + { + message = con + "\n Change appleEnableAutomaticSigning to: " + isAuto_Sign.ToString() + + "\n Change appleDeveloperTeamID to: " + SettingStringsKey.Instance.DeveloperTeamID; + } + + else + { + message = con + "\n Change appleEnableAutomaticSigning to: " + isAuto_Sign.ToString(); + } + +#elif UNITY_ANDROID + message = con + "\n Change targetSdkVersion to " + AndroidSdkVersions.AndroidApiLevel30; +#endif + if (EditorUtility.DisplayDialog("提示", message, "Yes", "No")) //显示对话框 + { +#if UNITY_IOS + Change(BuildTargetGroup.iOS, isAuto_Sign); +#elif UNITY_ANDROID + Change(BuildTargetGroup.Android, false); +#endif + } + + + + } + + + } + + + #region Setting参数处理 + + public static bool JoyPacSettingUpDate() + { + bool isAuto_Sign = false; + StringKeyManger.Instance.ClearStringKeyDic(StringKeyManger.Instance.BuildSettingKey); + JPReleaseAreaType releaseAreaType = JoyPacParamsManager.GetJPReleaseAreaType(); + +#if UNITY_IOS + IEnumerable JoyPacSettingFieldInfo = JoyPacParamsManager.GetBuildParamsFieldInfoByPlatformType(JPEditorPlatformType.iOS, releaseAreaType, JPEditorComponentType.JoyPacSetting); +#elif UNITY_ANDROID + IEnumerable JoyPacSettingFieldInfo = JoyPacParamsManager.GetBuildParamsFieldInfoByPlatformType(JPEditorPlatformType.Android, releaseAreaType, JPEditorComponentType.JoyPacSetting); +#elif UNITY_EDITOR + IEnumerable JoyPacSettingFieldInfo = JoyPacParamsManager.GetBuildParamsFieldInfoByPlatformType(JPEditorPlatformType.Editor, releaseAreaType, JPEditorComponentType.JoyPacSetting); +#endif + foreach (var info in JoyPacSettingFieldInfo) + { + + + if (info.FieldType == typeof(string)) + { + +#if UNITY_IOS + string jsonKey = info.Name.Remove(0, JoyPacParamsManager.RemoveCount); + + +#elif UNITY_ANDROID + string jsonKey = info.Name.Remove(0, JoyPacParamsManager.RemoveCount); +#elif UNITY_EDITOR + string jsonKey = ""; +#endif + StringKeyManger.Instance.AddStringKeyDic(jsonKey, (string)info.GetValue(AutomationManager.JoyPacBuildParams), StringKeyManger.Instance.BuildSettingKey); + + } + if (info.FieldType == (typeof(bool))) + { + isAuto_Sign = (bool)info.GetValue(AutomationManager.JoyPacBuildParams); + } + + } + StringKeyManger.Instance.SerializeDictionaryToJsonString(StringKeyManger.Instance.BuildSettingKey, StringKeyManger.Instance.BuildJsonPath); + AssetDatabase.Refresh(); + return isAuto_Sign; + + + } + + #region 更新Setting + public static void Change(BuildTargetGroup buildTargetGroup, bool isAuto_Sign) + { + + + PlayerSettings.productName = SettingStringsKey.Instance.productName; + PlayerSettings.bundleVersion = SettingStringsKey.Instance.bundleVersion; + PlayerSettings.SetApplicationIdentifier(buildTargetGroup, SettingStringsKey.Instance.BundleID); +#if UNITY_IOS + PlayerSettings.iOS.appleEnableAutomaticSigning = isAuto_Sign; + if (isAuto_Sign) + PlayerSettings.iOS.appleDeveloperTeamID = SettingStringsKey.Instance.DeveloperTeamID; +#elif UNITY_ANDROID + PlayerSettings.Android.targetSdkVersion = AndroidSdkVersions.AndroidApiLevel30; +#endif + + } + #endregion + + #endregion + + + + private void DrawIosPushBuildParams(JPReleaseAreaType releaseAreaType) + { + this.BeginDrawVerticalBox(); + this.DrawH1Title("iOS Platform Push Build Params"); + + var fieldInfos = JoyPacParamsManager.GetBuildParamsFieldInfoByPlatformType(JPEditorPlatformType.iOS, releaseAreaType, JPEditorComponentType.BuildPush); + foreach (var fieldInfo in fieldInfos) + { + this.DrawComponentByFieldInfo(fieldInfo); + } + this.EndDrawVerticalBox(); + } + + /// + /// 字段值被修改后调用的方法. + /// + /// 字段名称. + /// 修改后的值. + /// + private void FieldValueChange(string fieldName, object value) + { + var buildParams = AutomationManager.JoyPacBuildParams; + this.RefreshFieldValue(buildParams, fieldName, value); + EditorUtility.SetDirty(buildParams); + AssetDatabase.SaveAssets(); + AssetDatabase.Refresh(); + + string val = value.ToString(); + if (val == null || val == "") + return; + if (IsSpace(val.Substring(0, 1))) + JPPackageManager.ShowTips("Error", "value = " + val + " 第一个字符串为空格,请检查是否正确"); + + if (IsSpace(val.Substring(val.Length - 1, 1))) + JPPackageManager.ShowTips("Error", "value = " + val + " 最后一个字符串为空格,请检查是否正确"); + } + + private bool IsSpace(string name) + { + if (name.Trim().Length == 0) + { + return true; + } + return false; + } + + /// + /// 绘制不同字段类型的控件. + /// + /// 字段信息. + /// 是否继续绘制. + private void DrawComponentByFieldInfo(FieldInfo fieldInfo, bool isContinueDraw = true) + { + var attr = JoyPacParamsManager.GetInitFieldAttr(fieldInfo); + + // 不是控制开关并且外部条件不继续绘制则不绘制 + if (!attr.IsControllerSwitch && !isContinueDraw) + { + return; + } + + if (!string.IsNullOrEmpty(attr.Tip)) + { + EditorGUILayout.HelpBox(attr.Tip, MessageType.Info); + } + + if (fieldInfo.FieldType == typeof(bool)) + { + this.DrawToggle(attr.InspectorPropertyLabel, fieldInfo.Name); + } + else if (fieldInfo.FieldType == typeof(JoyPacParams.LoginMode)) + { + this.DrawEnumPopup(attr.InspectorPropertyLabel, fieldInfo.Name); + } + else if (fieldInfo.FieldType == typeof(string)) + { + this.DrawTextArea(attr.InspectorPropertyLabel, fieldInfo.Name); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacBuildParamsInspector.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacBuildParamsInspector.cs.meta new file mode 100644 index 00000000..1df217a2 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacBuildParamsInspector.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 781273c2603144f799c7f88a8bc8e5ed +timeCreated: 1616120492 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacInitParamsInspector.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacInitParamsInspector.cs new file mode 100644 index 00000000..2f21f0a6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacInitParamsInspector.cs @@ -0,0 +1,894 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Reflection; +using UnityEditor; +using UnityEditorInternal; +using UnityEngine; + +#if UNITY_EDITOR + +[CustomEditor(typeof(JoyPacParams))] +[Serializable] +public class JoyPacInitParamsInspector : BaseParamsInspector +{ + + //JPReleaseAreaType jPReleaseAreaType = JPReleaseAreaType.None; + // 面板渲染 + protected override void DrawInspector() + { + var JoyPacParams = this.mTargetObject; + // 注册字段值改变的监听 + this.FieldValueChangeListener = this.FieldValueChange; + + DrawEditorUi(JoyPacParams); + +#if UNITY_IOS + + // 绘制iosUi + this.DrawIosUi(JoyPacParams); + +#elif UNITY_ANDROID + // 绘制Android参数UI + this.DrawAndroidUi(JoyPacParams); +#endif + + } + + #region Draw Editor + + private void DrawEditorUi(JoyPacParams JoyPacParams) + { + this.BeginDrawVerticalBox(); + this.DrawSwitchArea(); +#if UNITY_IOS + this.DrawH1Title("Attention! \n The current platform is iOS"); +#elif UNITY_ANDROID + this.DrawH1Title("Attention! \n The current platform is Android"); +#endif + this.EndDrawVerticalBox(); + } + + + private void DrawSwitchArea() + { + this.BeginDrawVerticalBox(); + + +#if UNITY_IOS + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.iOS, + JPReleaseAreaType.Editor, + + JPEditorComponentType.Core); + +#elif UNITY_ANDROID + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.Android, + JPReleaseAreaType.Editor, + + JPEditorComponentType.Core); +#elif UNITY_EDITOR + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.Editor, + JPReleaseAreaType.Editor, JPEditorComponentType.Core); + + +#endif + + foreach (var fieldInfo in fieldInfos) + { + DrawComponentByFieldInfo(fieldInfo); + + string explain = ""; + if (fieldInfo.FieldType == typeof(JPReleaseAreaType)) + { + + JPReleaseAreaType jPReleaseAreaType = (JPReleaseAreaType)fieldInfo.GetValue(AutomationManager.JoyPacParams); + + switch (jPReleaseAreaType) + { + case JPReleaseAreaType.Editor: + explain = "请先选择当前要发布的地区 \n (Select the region you want to publish) \n CN --国内(China) OS--海外(no China)"; + + break; + case JPReleaseAreaType.CN: + + explain = "当前为国内地区(It is currently in China)"; + + break; + case JPReleaseAreaType.OS: + +#if UNITY_IOS + explain = "当前为海外地区(It is currently in no China)"; +#elif UNITY_ANDROID + explain = "当前为海外GP地区(It is currently in no China)"; +#endif + break; + } + } + + + + this.DrawH2Title(explain); + + } + + this.EndDrawVerticalBox(); + } + + + + + + + + #endregion + + + +#if UNITY_IOS + #region Draw iOS Platform Ui + + // 绘制iosUi + private void DrawIosUi(JoyPacParams JoyPacParams) + { + this.BeginDrawVerticalBox(); + + JPReleaseAreaType releaseAreaType = JoyPacParamsManager.GetJPReleaseAreaType(); + if (JPPackageManager.HasComponent(JPComponenetType.Ga_Adjust)) + { + // Ga_Adjust + this.DrawIosGa_AdjustParams(JoyPacParams, releaseAreaType); + switch (releaseAreaType) + { + case JPReleaseAreaType.CN: + if (JoyPacParams.iOSCN_IsHaveAdjustEvent) + this.DrawIosAdjustEventParams(JoyPacParams, releaseAreaType); + break; + case JPReleaseAreaType.OS: + if (JoyPacParams.iOSOS_IsHaveAdjustEvent) + this.DrawIosAdjustEventParams(JoyPacParams, releaseAreaType); + break; + + } + + } + + this.DrawIosJoyPacSetting(JoyPacParams, releaseAreaType); + if (JPPackageManager.HasComponent(JPComponenetType.Umeng)) + { + StringKeyManger.Instance.isHaveUmeng = true; + this.DrawIosUmengParams(JoyPacParams, releaseAreaType); + } + else + StringKeyManger.Instance.isHaveUmeng = false; + + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd)) + { + StringKeyManger.Instance.isHaveJoypacSDK = true; + this.DrawIosAdParams(JoyPacParams, releaseAreaType); + this.DrawIosCoreAdUi(JoyPacParams, releaseAreaType); + + + } + else + { + + StringKeyManger.Instance.isHaveJoypacSDK = false; + //att弹框仅在没有joypacSDK的时候可用 + this.DrawIosAttParams(JoyPacParams, releaseAreaType); + } + DrawIosPopUp(JoyPacParams, releaseAreaType); + + this.EndDrawVerticalBox(); + } + + + #region 绘制Ga_Adjust模块 + private void DrawIosGa_AdjustParams(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("iOS GameAnalytics和Adjust组件参数配置 \n【GameAnalytics and Adjust component parameters configuration】"); + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.iOS, + type, + + JPEditorComponentType.Ga_Adjust); + + foreach (var fieldInfo in fieldInfos) + { + if (fieldInfo.FieldType == typeof(string)) + { + DrawComponentByFieldInfo(fieldInfo); + } + if (fieldInfo.FieldType == typeof(bool)) + { + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd)) + DrawComponentByFieldInfo(fieldInfo); + } + + + } + + EndDrawVerticalBox(); + + } + + + #endregion + + #region 绘制Adjust事件模块 + private void DrawIosAdjustEventParams(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + + this.BeginDrawVerticalBox(); + this.DrawH2Title("iOS Adjust事件"); + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.iOS, type, + JPEditorComponentType.AdjustEvent); + + + + foreach (var fieldInfo in fieldInfos) + { + DrawComponentByFieldInfo(fieldInfo); + + } + + EndDrawVerticalBox(); + } + #endregion + + + #region 绘制弹框模块 + private void DrawIosPopUp(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + + this.BeginDrawVerticalBox(); + this.DrawH2Title("iOS 国内弹框参数"); + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.iOS, type, + JPEditorComponentType.Pop_Up); + + + + foreach (var fieldInfo in fieldInfos) + { + DrawComponentByFieldInfo(fieldInfo); + + } + + EndDrawVerticalBox(); + } + #endregion + + + + #region 绘制att弹框模块 + private void DrawIosAttParams(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("iOS att弹框,仅在无JP框架的时候使用"); + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.iOS, JPReleaseAreaType.Editor, + JPEditorComponentType.Att); + + foreach (var fieldInfo in fieldInfos) + { + DrawComponentByFieldInfo(fieldInfo); + } + + EndDrawVerticalBox(); + } + #endregion + + + + #region JoyPacSetting AppID + private void DrawIosJoyPacSetting(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + //this.BeginDrawVerticalBox(); + //this.DrawH2Title("请选择是否有评价弹出功能,默认为false"); + + //var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + // JPEditorPlatformType.iOS, + // type, + // JPEditorComponentType.JoyPacSetting); + + //foreach (var fieldInfo in fieldInfos) + //{ + // switch (type) + // { + // case JPReleaseAreaType.CN: + // if (fieldInfo.Name == "iOSCN_APPLE_APP_ID") + // { + // if (JoyPacParams.iOSCN_IsHaveAppraise) + // this.DrawComponentByFieldInfo(fieldInfo); + // } + // else + // { + // this.DrawComponentByFieldInfo(fieldInfo); + // } + // break; + // case JPReleaseAreaType.OS: + // if (fieldInfo.Name == "iOSOS_APPLE_APP_ID") + // { + // if (JoyPacParams.iOSOS_IsHaveAppraise) + // this.DrawComponentByFieldInfo(fieldInfo); + // } + // else + // { + // this.DrawComponentByFieldInfo(fieldInfo); + // } + // break; + + // } + + + //} + + //EndDrawVerticalBox(); + + } + #endregion + + + #region 绘制友盟模块 + private void DrawIosUmengParams(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("Umeng分析【Umeng analysis】"); + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.iOS, type, + JPEditorComponentType.Umeng); + + foreach (var fieldInfo in fieldInfos) + { + DrawComponentByFieldInfo(fieldInfo); + } + + EndDrawVerticalBox(); + } + #endregion + + #region 绘制iOS-JoyPacSDK参数配置 + private void DrawIosAdParams(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("JoyPacSDK参数配置【JoyPacSDK parameter configuration】"); + + var adnFieldInfo = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.iOS, type, + JPEditorComponentType.AdParams); + foreach (var fieldInfo in adnFieldInfo) + { + + this.DrawComponentByFieldInfo(fieldInfo); + } + this.EndDrawVerticalBox(); + } + #endregion + + + #region 绘制iOS-Core-Ad-Net UI + /// + /// 测试阶段广告 + /// + /// + private void DrawIosCoreAdUi(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("JoyPacSDK AdN参数配置 \n 【JoyPacSDK AdN parameter configuration】"); + + // 绘制ADN类型 + var adnFieldInfo = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.iOS, type, + JPEditorComponentType.AdNet); + foreach (var fieldInfo in adnFieldInfo) + { + this.DrawComponentByFieldInfo(fieldInfo); + } + this.EndDrawVerticalBox(); + } + + + #endregion + + #endregion + +#endif + + +#if UNITY_ANDROID + #region Draw ANDROID Platform Ui + + // 绘制iosUi + private void DrawAndroidUi(JoyPacParams JoyPacParams) + { + // 绘制android参数UI + this.BeginDrawVerticalBox(); + + JPReleaseAreaType releaseAreaType = JoyPacParamsManager.GetJPReleaseAreaType(); + + + if (JPPackageManager.HasComponent(JPComponenetType.Ga_Adjust)) + { + // 绘制Ga_Adjust模块参数 + this.DrawAndroidGa_AdjustParams(JoyPacParams, releaseAreaType); + if (JoyPacParams.AndroidOS_IsHaveAdjustEvent) + this.DrawAndroidAdjustEventParams(JoyPacParams, releaseAreaType); + } + + if (releaseAreaType == JPReleaseAreaType.OS) + { + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd_Android)) + { + this.DrawAndroidUmengParams(JoyPacParams, releaseAreaType); + this.DrawAndroidAdParams(JoyPacParams, releaseAreaType); + this.DrawAdnParams(JoyPacParams, releaseAreaType); + this.DrawPropertiesParams(JoyPacParams, releaseAreaType); + + } + } + else + { + this.DrawAndroidAdParams(JoyPacParams, releaseAreaType); + } + + this.EndDrawVerticalBox(); + + + } + + + + + // 绘制Ga_Adjust模块 + private void DrawAndroidGa_AdjustParams(JoyPacParams JoyPacParams, JPReleaseAreaType jPReleaseAreaType) + { + this.BeginDrawVerticalBox(); + + + this.DrawH2Title("Android GameAnalytics和Adjust组件参数配置 \n 【GameAnalytics and Adjust component parameters configuration】"); + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.Android, + jPReleaseAreaType, + + JPEditorComponentType.Ga_Adjust); + + + foreach (var fieldInfo in fieldInfos) + { + DrawComponentByFieldInfo(fieldInfo); + + } + + EndDrawVerticalBox(); + } + + #region 绘制Adjust事件模块 + private void DrawAndroidAdjustEventParams(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + + this.BeginDrawVerticalBox(); + this.DrawH2Title("Android Adjust事件【Android Adjust event】"); + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.Android, type, + JPEditorComponentType.AdjustEvent); + + + + foreach (var fieldInfo in fieldInfos) + { + DrawComponentByFieldInfo(fieldInfo); + + } + + EndDrawVerticalBox(); + } + #endregion + + #region 绘制友盟模块 + private void DrawAndroidUmengParams(JoyPacParams JoyPacParams, JPReleaseAreaType type) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("Umeng分析【Umeng analysis】"); + + var fieldInfos = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.Android, type, + JPEditorComponentType.Umeng); + + foreach (var fieldInfo in fieldInfos) + { + DrawComponentByFieldInfo(fieldInfo); + } + + EndDrawVerticalBox(); + } + #endregion + private void DrawAndroidAdParams(JoyPacParams JoyPacParams, JPReleaseAreaType jPReleaseAreaType) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("JoyPacSDK参数配置【JoyPacSDK parameter configuration】"); + + var adnFieldInfo = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.Android, jPReleaseAreaType, + JPEditorComponentType.AdParams); + foreach (var fieldInfo in adnFieldInfo) + { + + this.DrawComponentByFieldInfo(fieldInfo); + } + this.EndDrawVerticalBox(); + + } + + + private void DrawAdnParams(JoyPacParams JoyPacParams, JPReleaseAreaType jPReleaseAreaType) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("JoyPacSDK AdN参数配置 \n 【JoyPacSDK AdN parameter configuration】 "); + + var adnFieldInfo = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.Android, jPReleaseAreaType, + JPEditorComponentType.AdNet); + foreach (var fieldInfo in adnFieldInfo) + { + + this.DrawComponentByFieldInfo(fieldInfo); + } + this.EndDrawVerticalBox(); + + this.DrawH1Title("UmengAppKey和\n Android_Admob_GADApplicationIdentifier \n更改后点击下方按钮更新AndroidManifest文件 "); + + ButtonAndroidManifest(); + + } + + private void ButtonAndroidManifest() + { + + if (GUILayout.Button("更新AndroidManifest文件(Update AndroidManifest file)", GUILayout.Width(500), GUILayout.Height(50))) + { + + string message = "确认更新AndroidManifest文件 (Update AndroidManifest file)"; + + if (EditorUtility.DisplayDialog("提示", message, "Yes", "No")) //显示对话框 + { + JoyPacParamsManager.WriteXmlKey("", ""); + + } + + + + } + + + } + private void DrawPropertiesParams(JoyPacParams JoyPacParams, JPReleaseAreaType jPReleaseAreaType) + { + this.BeginDrawVerticalBox(); + this.DrawH2Title("Properties文件另外所需参数,更改后需点击下方按钮进行更新 \n 【Properties file for additional parameters, \n click the button below to update after change】"); + + var adnFieldInfo = JoyPacParamsManager.GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType.Android, jPReleaseAreaType, + JPEditorComponentType.Properties); + foreach (var fieldInfo in adnFieldInfo) + { + + this.DrawComponentByFieldInfo(fieldInfo); + } + this.EndDrawVerticalBox(); + ButtonProperties(); + } + + + private void ButtonProperties() + { + + if (GUILayout.Button("更新Properties文件 (Update Properties file)", GUILayout.Width(500), GUILayout.Height(50))) + { + + string message = "确认更新Properties文件 (Update Properties file)"; + + if (EditorUtility.DisplayDialog("提示", message, "Yes", "No")) //显示对话框 + { + JoyPacParamsManager.WriteProperties(true); + + } + + + + } + + + } + private void DrawIosPayUi() + { + //BeginDrawVerticalBox(); + //DrawH2Title("iOS Pay 模块"); + //DrawLabel("iOS_Pay_Key", JPiOSConfig.Config.Payment.PayKey,"用于生成支付签名"); + //EndDrawVerticalBox(); + } + + + + + + #endregion +#endif + /// + /// 绘制不同字段类型的控件. + /// + /// 字段信息. + /// 是否继续绘制. + private void DrawComponentByFieldInfo(FieldInfo fieldInfo, bool isContinueDraw = true) + { + var attr = JoyPacParamsManager.GetInitFieldAttr(fieldInfo); + + // 不是控制开关并且外部条件不继续绘制则不尽兴绘制 + if (!attr.IsControllerSwitch && !isContinueDraw) + { + return; + } + + if (!string.IsNullOrEmpty(attr.Tip)) + { + EditorGUILayout.HelpBox(attr.Tip, MessageType.Info); + } + if (fieldInfo.FieldType == typeof(bool)) + { + this.DrawToggle(attr.InspectorPropertyLabel, fieldInfo.Name); + } + else if (fieldInfo.FieldType.BaseType == typeof(Enum)) + { + this.DrawEnumPopup(attr.InspectorPropertyLabel, fieldInfo.Name); + } + else if (fieldInfo.FieldType == typeof(string)) + { + this.DrawTextArea(attr.InspectorPropertyLabel, fieldInfo.Name); + } + + } + + + /// + /// 字段在面板中被修改监听. + /// + /// 字段名. + /// 要修改的值. + private void FieldValueChange(string fieldName, object value) + { + JoyPacParamsManager.FieldValueChange(fieldName, value); + var attr = JoyPacParamsManager.GetInitAttrByFieldName(fieldName); + // Adn选择处理 + + + ComponentType_Core(attr, fieldName, value); + + ComponentType_AdNet(attr, fieldName, value); + + string val = value.ToString(); + if (val == null || val == "") + return; + if (IsSpace(val.Substring(0, 1))) + JPPackageManager.ShowTips("Error", "value = " + val + " 第一个字符串为空格,请检查是否正确"); + + if (IsSpace(val.Substring(val.Length - 1, 1))) + JPPackageManager.ShowTips("Error", "value = " + val + " 最后一个字符串为空格,请检查是否正确"); + + + + } + + + private bool IsSpace(string name) + { + if (name.Trim().Length == 0) + { + return true; + } + return false; + } + + #region FieldValueChange + + + private void ComponentType_Core(InspectorGameParamsAttribute attr, string fieldName, object value) + { + if (attr.ComponentType == JPEditorComponentType.Core) + { + if (value.GetType() == typeof(JPReleaseAreaType)) + { + + + switch ((JPReleaseAreaType)value) + { + + case JPReleaseAreaType.Editor: + JPPackageManager.ShowTips("Error", "只能请选择CN(国内)或者OS(非国内)【Please select CN(China) or OS(not China)】"); + + break; + case JPReleaseAreaType.CN: +#if UNITY_IOS + JPPackageManager.ShowTips("提示", "确认切换为国内地区(The local area has been switched to China"); + + JPPackageManager.iOS_Adn_Info(JPReleaseAreaType.CN); + + string str = PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android); + + +#elif UNITY_ANDROID + JPPackageManager.ShowTips("提示", "安卓CN仅支持内部使用,外部开发请选择OS(海外,GP)【Android CN only supports internal use, please select OS for external development】"); + SwitchArea_Android(JPReleaseAreaType.CN); +#endif + + break; + case JPReleaseAreaType.OS: + +#if UNITY_IOS + JPPackageManager.ShowTips("提示", "确认切换为海外地区(The local area has been switched to no China"); + + JPPackageManager.iOS_Adn_Info(JPReleaseAreaType.OS); + + + +#elif UNITY_ANDROID + JPPackageManager.ShowTips("提示", "确认切换为海外GP地区(The local area has been switched to no China【GP】)"); + SwitchArea_Android(JPReleaseAreaType.OS); +#endif + + break; + } + + + } + + + + } + + } + + private void SwitchArea_Android(JPReleaseAreaType jPReleaseAreaType) + { + string Android_AD = Application.dataPath + "/" + "JoyPacSDK/JoyPacAd_Android"; + string Android_FB = Application.dataPath + "/" + "FacebookSDK"; + + string Android_Manifest = Application.dataPath + "/" + "Plugins/Android/AndroidManifest.xml"; + string Android_Raw = Application.dataPath + "/" + "Plugins/Android/res/raw"; + + + + string str = PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android); + Debug.Log("old " + str); + str = str.Replace("ANDROID_GP", null); + if (jPReleaseAreaType == JPReleaseAreaType.CN) + { + + JPChannel.HidePath(Android_AD); + JPChannel.HideFile(Android_Manifest); + JPChannel.HidePath(Android_Raw); + JPChannel.HidePath(Android_FB); + Debug.Log("切换CN"); + PlayerSettings.SetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android, + str); + Debug.Log("new " + PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android)); + } + else if (jPReleaseAreaType == JPReleaseAreaType.OS) + { + if (File.Exists(Android_Manifest)) + File.Delete(Android_Manifest); + JPChannel.ShowPath(Android_AD); + JPChannel.showFile(Android_Manifest); + JPChannel.ShowPath(Android_Raw); + JPChannel.ShowPath(Android_FB); + + PlayerSettings.SetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android, + "ANDROID_GP" + ";" + str); + Debug.Log("new " + PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android)); + + + Debug.Log("切换OS"); + } + + AssetDatabase.Refresh(); + + } + + private void ComponentType_AdNet(InspectorGameParamsAttribute attr, string fieldName, object value) + { + + + if (attr.ComponentType == JPEditorComponentType.AdNet) + { + + + if (value.GetType() == typeof(bool)) + { + string jsonKey = fieldName.Remove(3, 2); + switch (jsonKey) + { + + case "iOS_Admob": + JPPackageManager.iOS_Adn_Handle(JPAdNType.admob, (bool)value); + break; + case "iOS_IronSource": + JPPackageManager.iOS_Adn_Handle(JPAdNType.ironsource, (bool)value); + break; + case "iOS_GDT": + JPPackageManager.iOS_Adn_Handle(JPAdNType.gdt, (bool)value); + break; + case "iOS_UnityAd": + JPPackageManager.iOS_Adn_Handle(JPAdNType.unityads, (bool)value); + break; + case "iOS_Vungle": + JPPackageManager.iOS_Adn_Handle(JPAdNType.vungle, (bool)value); + break; + case "iOS_Mintegral": + JPPackageManager.iOS_Adn_Handle(JPAdNType.mintegral, (bool)value); + break; + + // -------------------------------------------以下为测试阶段不需要------------------------------------------------------------------ + case "iOS_KS": + JPPackageManager.iOS_Adn_Handle(JPAdNType.kuaishou, (bool)value); + break; + case "iOS_Pangle_China": + JPPackageManager.iOS_Adn_Handle(JPAdNType.pangle_China, (bool)value); + + break; + case "iOS_Pangle_nonChina": + JPPackageManager.iOS_Adn_Handle(JPAdNType.pangle_nonChina, (bool)value); + + break; + case "iOS_Applovin": + JPPackageManager.iOS_Adn_Handle(JPAdNType.applovin, (bool)value); + + break; + case "iOS_KlevinSDK": + JPPackageManager.iOS_Adn_Handle(JPAdNType.KlevinSDK, (bool)value); + break; + case "iOS_Adcolony": + JPPackageManager.iOS_Adn_Handle(JPAdNType.adcolony, (bool)value); + + break; + case "iOS_Maio": + JPPackageManager.iOS_Adn_Handle(JPAdNType.maio, (bool)value); + break; + case "iOS_Chartboost": + JPPackageManager.iOS_Adn_Handle(JPAdNType.chartboost, (bool)value); + break; + case "iOS_FaceBook": + JPPackageManager.iOS_Adn_Handle(JPAdNType.facebook, (bool)value); + break; + case "iOS_Fyber": + JPPackageManager.iOS_Adn_Handle(JPAdNType.fyber, (bool)value); + break; + } + + + + } + } + } + #endregion + + + + // 动态权限,可增删列表UI + private ReorderableList Android_Permission_ReorderableList; + + +} + + +#endif diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacInitParamsInspector.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacInitParamsInspector.cs.meta new file mode 100644 index 00000000..4f5dec76 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Inspector/JoyPacInitParamsInspector.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 21c147f92b164edebf571ef9ad2e3573 +timeCreated: 1615184248 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JPConfigManager.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JPConfigManager.cs new file mode 100644 index 00000000..38d25a85 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JPConfigManager.cs @@ -0,0 +1,15 @@ +using UnityEditor.Build; +using UnityEditor.Build.Reporting; + + public class JPConfigManager : IPreprocessBuildWithReport + { + public int callbackOrder => 0; + public async void OnPreprocessBuild(BuildReport report) + { +#if UNITY_IOS + // await JPiOSConfig.Download2(); +#elif UNITY_ANDROID + // await JPAndroidConfig.Download2(); +#endif + } + } diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JPConfigManager.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JPConfigManager.cs.meta new file mode 100644 index 00000000..56e77712 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JPConfigManager.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: c6d14ccd642546f9aa583017d426f418 +timeCreated: 1624531043 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JoyPacSDKInitializeOnLoad.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JoyPacSDKInitializeOnLoad.cs new file mode 100644 index 00000000..e81f10df --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JoyPacSDKInitializeOnLoad.cs @@ -0,0 +1,11 @@ +using UnityEditor; + + [InitializeOnLoad] + public class JoyPacSDKInitializeOnLoad + { + static JoyPacSDKInitializeOnLoad() + { + // 更新构建脚本. + BuildScriptManager.UpdateBuildScriptContent(); + } + } diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JoyPacSDKInitializeOnLoad.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JoyPacSDKInitializeOnLoad.cs.meta new file mode 100644 index 00000000..5d2a1173 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/JoyPacSDKInitializeOnLoad.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 21747c0a085e74a33ad2f908b217b38a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu.meta new file mode 100644 index 00000000..74d5728b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 7cadbf2a29724854b4793a352675c238 +timeCreated: 1615529856 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JPMenuName.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JPMenuName.cs new file mode 100644 index 00000000..6dd01710 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JPMenuName.cs @@ -0,0 +1,41 @@ + +public static class JPMenuName +{ + // JoyPacSdk + private const string SDK = "JoyPacSDK/"; + + // 包管理菜单 + private const string PackageManagerMenu = SDK + "一键输出SDK/"; + + // 最终包 + public const string SdkFinalPackage = PackageManagerMenu + "打出最终完整SDK包(SDK研发使用)"; + public const string SdkCPAPackage = PackageManagerMenu + "最小CPA测试SDK包(SDK研发使用)"; + public const string SdkVersionTestPackage = PackageManagerMenu + "最小版本测试SDK包(SDK研发使用)"; + + + + // 构建菜单 + private const string BUILD = SDK + "一键打包(Rapid Packaging)/"; + + // 构建Apk + //public const string BUILD_DEBUG_APK = BUILD + "输出APK/Debug版本"; + //public const string BUILD_RELEASE_APK = BUILD + "输出APK/Release版本"; + + // 构建ipa + //public const string BUILD_DEBUG_IPA = BUILD + "输出IPA/Debug版本"; + //public const string BUILD_RELEASE_IPA = BUILD + "输出IPA/Release版本"; + public const string BUILD_DEBUG_XCODE = BUILD + "导出(Export Xcode)/Debug版本"; + public const string BUILD_RELEASE_XCODE = BUILD + "导出(Export Xcode)/Release版本"; + + + // 参数面板 + + + + private const string Params_Inspector = SDK + "参数配置(Parameter configuration)/"; + + public const string Open_Params_InspectorCN = Params_Inspector + "/" + "打开参数面板(Open Parameters)"; + public const string Open_BuildParams_InspectorCN = Params_Inspector + "打开构建参数面板(Open build Parameters)"; + + public const string Switching_Platform = SDK + "切换 JoypacService-info文件(Switching JoypacService-info)"; +} diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JPMenuName.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JPMenuName.cs.meta new file mode 100644 index 00000000..6dbda85b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JPMenuName.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 39c567825cc8d4e2a9edc413ad3aacf8 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JoyPacSDKMenu.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JoyPacSDKMenu.cs new file mode 100644 index 00000000..a1e7b02d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JoyPacSDKMenu.cs @@ -0,0 +1,30 @@ +using System.Collections.Generic; +using System.IO; +using System.Reflection; +using System.Threading.Tasks; +using UnityEditor; +using UnityEditor.SceneManagement; +using UnityEngine.SceneManagement; + +public static class JoyPacSDKMenu +{ + [MenuItem(JPMenuName.Open_Params_InspectorCN)] + private static async Task OpenParamsInspectorScene() + { + + Selection.activeObject = JoyPacParams.Instance; + } + + [MenuItem(JPMenuName.Open_BuildParams_InspectorCN)] + private static void OpenBuildParamsInspectorScene() + { + Selection.activeObject = JoyPacBuildParams.Instance; + } + + + +} + + + + diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JoyPacSDKMenu.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JoyPacSDKMenu.cs.meta new file mode 100644 index 00000000..efcb9d07 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Menu/JoyPacSDKMenu.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 23e03180aeaf41a6b98356d5f9d3c8c0 +timeCreated: 1618469099 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/PackageExportManger.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/PackageExportManger.cs new file mode 100644 index 00000000..5074f729 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/PackageExportManger.cs @@ -0,0 +1,121 @@ +//using System.Collections; +//using System.Collections.Generic; +//using UnityEngine; + + + +//using System; + +//using UnityEditor; +//using UnityEngine; +//using System.IO; + + +///// +///// Package导出 +///// +//public class PackageExportManger +//{ + + +// private static List fileList = new List(); + +// // private const string SdkNamePreFix = "JoyPac_SDK"; +// private static string exportedFileName = "JoyPac_SDK"; +// private static string assetsPath = "Assets"; +// /// +// /// 获取路径下所有文件以及子文件夹中文件 +// /// +// /// 全路径根目录 +// /// 存放所有文件的全路径 +// /// +// public static List GetFile(string path, List FileList) +// { + +// DirectoryInfo dir = new DirectoryInfo(path); +// FileInfo[] fil = dir.GetFiles(); +// DirectoryInfo[] dii = dir.GetDirectories(); +// foreach (FileInfo f in fil) +// { + +// long size = f.Length; +// FileList.Add(f.FullName);//添加文件路径到列表中 +// } +// //获取子文件夹内的文件列表,递归遍历 +// foreach (DirectoryInfo d in dii) +// { + +// if (d.FullName == assetsPath + "/JoyPacSDK/JoyPacAd") +// continue; +// if (d.FullName == assetsPath + "/JoyPacSDK/JoyPacAd_Android") +// continue; +// if (d.FullName == assetsPath + "/JoyPacSDK/Resources") +// continue; +// if (d.FullName == assetsPath + "/Resources/JoyPacJSON") +// continue; +// GetFile(d.FullName, FileList); +// } +// return FileList; +// } + +// private static void GetShowFile(string rootPath) +// { +// if (string.IsNullOrEmpty(rootPath)) +// return; + + +// var files = GetFile(rootPath, fileList); + +// //for (int i = 0; i < files.Count; i++) +// //{ +// // string info = new DirectoryInfo(files[i]).Name; + +// // Debug.Log(info); +// // if (Path.GetExtension(info) == ".meta") +// // { +// // fileList.Remove(files[i]); +// // } +// //} + +// //foreach (var item in fileList) +// //{ +// // Debug.Log(item); +// //} +// } +// [MenuItem("JoyPacSDK/JoyPac/Export Unity Package")] +// public static void test() +// { + +// string Examples = assetsPath + "/Examples"; +// GetShowFile(Examples); + +// string Joypac = assetsPath + "/Joypac"; +// GetShowFile(Joypac); + +// string I2 = assetsPath + "/I2"; +// GetShowFile(I2); + +// string JPChannel = assetsPath + "/JPChannel"; +// GetShowFile(JPChannel); + +// string Other = assetsPath + "/Other"; +// GetShowFile(Other); + +// string JoyPacSDK = assetsPath + "/JoyPacSDK"; +// GetShowFile(JoyPacSDK); +// string Resources = assetsPath + "/Resources"; +// GetShowFile(Resources); + +// foreach (var item in fileList.ToArray()) +// { +// Debug.Log(item); +// } +// AssetDatabase.ExportPackage( +// fileList.ToArray(), +// exportedFileName, + +// ExportPackageOptions.IncludeDependencies | ExportPackageOptions.Interactive); + +// } + +//} diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/PackageExportManger.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/PackageExportManger.cs.meta new file mode 100644 index 00000000..467ce26b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/PackageExportManger.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: f3190ae7dd7a240c1bd689f4a133ad04 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils.meta new file mode 100644 index 00000000..32b17923 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: b225c16ca63245bd9b2b71503051e933 +timeCreated: 1625540328 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils/JPEditorPrefsHelper.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils/JPEditorPrefsHelper.cs new file mode 100644 index 00000000..6ec65544 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils/JPEditorPrefsHelper.cs @@ -0,0 +1,24 @@ +using UnityEditor; + + + public class JPEditorPrefsHelper + { + public static EditorSkinType CurrentSkinType + { + get + { + var userSkinInt = EditorPrefs.GetInt("UserSkin", 0); + return userSkinInt == 1 ? EditorSkinType.Dark : EditorSkinType.Light; + } + } + } + + // Unity 编辑器当前设置的主题颜色 + public enum EditorSkinType : int + { + // 白色主题 + Light = 0, + + // 黑色主题 + Dark = 1, + } diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils/JPEditorPrefsHelper.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils/JPEditorPrefsHelper.cs.meta new file mode 100644 index 00000000..59687f1b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Editor/Utils/JPEditorPrefsHelper.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 8084532a788d412ba58c9cd405b45bcd +timeCreated: 1625540386 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Params.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Params.meta new file mode 100644 index 00000000..69f5aca3 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Params.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 85868a61a89e4d148a34a6e121fe547a +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacBuildParams.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacBuildParams.cs new file mode 100644 index 00000000..61092ebe --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacBuildParams.cs @@ -0,0 +1,160 @@ +#if UNITY_EDITOR +using System.Collections.Generic; +using System.Reflection; +using UnityEditor; +using UnityEngine; + + +public class JoyPacBuildParams : ScriptableObject +{ + private const string JoyPacDir = "Assets/JoyPacSDK"; + + private const string JoyPacResDir = "Assets/JoyPacSDK/Resources"; + + private const string JoyPacParamsFile = + "Assets/JoyPacSDK/Resources/JoyPacBuildParams.asset"; + + + private static JoyPacBuildParams instance; + public static JoyPacBuildParams Instance + { + get + { + if (instance == null) + { + if (!AssetDatabase.IsValidFolder(JoyPacDir)) + { + AssetDatabase.CreateFolder("Assets", "JoyPacSDK"); + } + + if (!AssetDatabase.IsValidFolder(JoyPacResDir)) + { + AssetDatabase.CreateFolder(JoyPacDir, "Resources"); + } + + instance = (JoyPacBuildParams)AssetDatabase.LoadAssetAtPath( + JoyPacParamsFile, typeof(JoyPacBuildParams)); + + if (instance == null) + { + instance = ScriptableObject.CreateInstance(); + AssetDatabase.CreateAsset(instance, JoyPacParamsFile); + } + } + return instance; + } + } + + internal void WriteSettingsToFile() + { + AssetDatabase.SaveAssets(); + } + + #region iOS端构建参数配置 + + + #region iOS_JoyPacSetting--------------CN + + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.JoyPacSetting, "productName", "", + false, "国内参数: productName(必填)")] + public string iOSCN_productName; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.JoyPacSetting, "bundleVersion", + "", false, "国内参数: bundleVersion(必填)")] + public string iOSCN_bundleVersion; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.JoyPacSetting, "BundleID", + "", false, "国内参数: BundleID(必填)")] + public string iOSCN_BundleID; + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.JoyPacSetting, "Automaticall Sign", + "", true, "国内参数: Automaticall Sign")] + public bool iOSCN_Automaticall_Sign; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.JoyPacSetting, "DeveloperTeamID", + "", false, "国内参数: DeveloperTeamID(必填) ")] + public string iOSCN_DeveloperTeamID; + + + + #endregion + + + + #region iOS_JoyPacSetting--------------OS + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "productName", "", + false, "海外参数: productName(必填)")] + public string iOSOS_productName; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "bundleVersion", + "", false, "海外参数: bundleVersion(必填)")] + public string iOSOS_bundleVersion; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "BundleID", + "", false, "海外参数: BundleID(必填)")] + public string iOSOS_BundleID; + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "Automaticall Sign", + "", true, "海外参数: Automaticall Sign")] + public bool iOSOS_Automaticall_Sign; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "DeveloperTeamID", + "", false, "海外参数: DeveloperTeamID(必填) ")] + public string iOSOS_DeveloperTeamID; + + #endregion + + #endregion + + + #region Android端构建参数配置 + + + #region Android_JoyPacSetting--------------OS + + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "productName", "", + false, "海外参数: productName(必填)")] + public string AndroidOS_productName; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "bundleVersion", + "", false, "海外参数: bundleVersion(必填)")] + public string AndroidOS_bundleVersion; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "BundleID", + "", false, "海外参数: BundleID(必填)")] + public string AndroidOS_BundleID; + + + + #endregion + + + #endregion + + + + + + +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacBuildParams.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacBuildParams.cs.meta new file mode 100644 index 00000000..514d4207 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacBuildParams.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 6d485789450d49d68846cd7ed916ed63 +timeCreated: 1616120348 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParams.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParams.cs new file mode 100644 index 00000000..5b5bf47e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParams.cs @@ -0,0 +1,911 @@ +#if UNITY_EDITOR +using System.Collections.Generic; +using UnityEditor; +using UnityEngine; + +public class JoyPacParams : ScriptableObject +{ + + private const string JoyPacDir = "Assets/JoyPacSDK"; + + private const string JoyPacResDir = "Assets/JoyPacSDK/Resources"; + + private const string JoyPacParamsFile = + "Assets/JoyPacSDK/Resources/JoyPacParams.asset"; + + + + private static JoyPacParams instance; + public static JoyPacParams Instance + { + get + { + if (instance == null) + { + if (!AssetDatabase.IsValidFolder(JoyPacDir)) + { + AssetDatabase.CreateFolder("Assets", "JoyPacSDK"); + } + + if (!AssetDatabase.IsValidFolder(JoyPacResDir)) + { + AssetDatabase.CreateFolder(JoyPacDir, "Resources"); + } + + instance = (JoyPacParams)AssetDatabase.LoadAssetAtPath( + JoyPacParamsFile, typeof(JoyPacParams)); + + if (instance == null) + { + instance = ScriptableObject.CreateInstance(); + AssetDatabase.CreateAsset(instance, JoyPacParamsFile); + } + } + return instance; + } + } + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.Editor, JPEditorComponentType.Core, "ReleaseArea", "", + false, "当前为iOS平台,请先选择当前要发布的地区 \n 【Note If the iOS platform is used, select the region to be published】")] + public JPReleaseAreaType iOS_jPReleaseAreaType = JPReleaseAreaType.OS; + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.Editor, JPEditorComponentType.Core, "ReleaseArea", "", + false, "当前为Android平台,请先选择当前要发布的地区 \n 【Note If the Android platform is used, select the region to be published】")] + public JPReleaseAreaType Android_jPReleaseAreaType = JPReleaseAreaType.OS; + + + #region iOS + + #region iOS-Ga-Adjust--------------CN + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "AdjustDeeplink", "", + false, "国内参数【Domestic parameters】: AdjustDeeplink(非必填)")] + public string iOSCN_AdjustDeeplink; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "ADJUST_APP_TOKEN", + "", false, "国内参数【Domestic parameters】: ADJUST_APP_TOKEN(必填)【required】")] + public string iOSCN_ADJUST_APP_TOKEN; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "GA_GAME KEY", + "", false, "国内参数【Domestic parameters】: GA_GAME KEY(必填)【required】")] + public string iOSCN_GA_gameKey; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "GA_SECRET KEY", + "", false, "国内参数【Domestic parameters】: GA_SECRET KEY(必填)【required】")] + public string iOSCN_GA_secretKey; + + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "IsHaveAdjustEvent", + "", true, "请选择 是否有adjust事件【IsHaveAdjustEvent parameter】(必填)【required】")] + public bool iOSCN_IsHaveAdjustEvent; + + + #region adjust Event CN + + // [SerializeField] + // [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "Native展示【Native ad shows】", + //"", false, "国内参数【Domestic parameters】: NATIVE_SHOW_TOKEN(必填)【required】")] + // public string iOSCN_NATIVE_SHOW_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "判断当前设备是ipad的事件token【Device model is iPad】", + "", false, "国内参数【Domestic parameters】: DEVICEINFO_IPAD_TOKEN(必填)【required】")] + public string iOSCN_DEVICEINFO_IPAD_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "判断当前设备是iphone的事件token【Device model is iphone】", + "", false, "国内参数【Domestic parameters】: DEVICEINFO_IPHONE_TOKEN(必填)【required】")] + public string iOSCN_DEVICEINFO_IPHONE_TOKEN; + + // [SerializeField] + // [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "成功十次【Level complete 10 times】", + //"", false, "国内参数【Domestic parameters】: PLAY_10_TOKEN(必填)【required】")] + // public string iOSCN_PLAY_10_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "插屏展示【IV ad shows】", + "", false, "国内参数【Domestic parameters】: INTERSITIAL_SHOW_COUNT_TOKEN(必填)【required】")] + public string iOSCN_INTERSITIAL_SHOW_COUNT_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "次日启动【Reopen app on the next day】", + "", false, "国内参数【Domestic parameters】: SECOND_LAUNCH_DAY_TOKEN(必填)【required】")] + public string iOSCN_SECOND_LAUNCH_DAY_TOKEN; + + // [SerializeField] + // [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "游戏次数【Game played time】", + //"", false, "国内参数【Domestic parameters】: GAME_FINISH(必填)【required】")] + // public string iOSCN_GAME_FINISH; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "激励视频展示【RV ad shows】", + "", false, "国内参数【Domestic parameters】: VIDEO_SHOW_COUNT_TOKEN(必填)【required】")] + public string iOSCN_VIDEO_SHOW_COUNT_TOKEN; + + // [SerializeField] + // [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "视频+插屏上报【IV+RV ad showed report】", + //"", false, "国内参数【Domestic parameters】: VIDEO_AND_INTERITIAL_COUNT_TOKEN(必填)【required】")] + // public string iOSCN_VIDEO_AND_INTERITIAL_COUNT_TOKEN; + + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "评价主动弹出事件token【AppStore rating window pops up report】", + // "", false, "国内参数【Domestic parameters】: FIRST_RATE_TOKEN(必填)【required】")] + //public string iOSCN_FIRST_RATE_TOKEN; + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "累计N次RVIV视频【RV+IV ad showed X time】", +"", false, "国内参数【Domestic parameters】: ADJUST_EVENT_RVIV24(必填)【required】")] + public string iOSCN_ADJUST_EVENT_RVIV24; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "累计N次RV视频【RV ad showed X time】", + "", false, "国内参数【Domestic parameters】: ADJUST_EVENT_RV24(必填)【required】")] + public string iOSCN_ADJUST_EVENT_RV24; + + #endregion + + #endregion + + + #region iOS-Ga-Adjust--------------OS + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "AdjustDeeplink", "", + false, "海外参数【Overseas parameters】: AdjustDeeplink(非必填)")] + public string iOSOS_AdjustDeeplink; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "ADJUST_APP_TOKEN", + "", false, "海外参数【Overseas parameters】: ADJUST_APP_TOKEN(必填)【required】")] + public string iOSOS_ADJUST_APP_TOKEN; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "GA_GAME KEY", + "", false, "海外参数【Overseas parameters】: GA_GAME KEY(必填)【required】")] + public string iOSOS_GA_gameKey; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "GA_SECRET KEY", + "", false, "海外参数【Overseas parameters】: GA_SECRET KEY(必填)【required】")] + public string iOSOS_GA_secretKey; + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "IsHaveAdjustEvent", + "", true, "请选择 是否有adjust事件【IsHaveAdjustEvent parameter】(必填)【required】")] + public bool iOSOS_IsHaveAdjustEvent; + + #region adjust Event + + // [SerializeField] + // [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "Native展示【Native ad shows】", + //"", false, "海外参数【Overseas parameters】: NATIVE_SHOW_TOKEN(必填)【required】")] + // public string iOSOS_NATIVE_SHOW_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "判断当前设备是ipad的事件token【Device model is iPad】", + "", false, "海外参数【Overseas parameters】: DEVICEINFO_IPAD_TOKEN(必填)【required】")] + public string iOSOS_DEVICEINFO_IPAD_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "判断当前设备是iphone的事件token【Device model is iphone】", + "", false, "海外参数【Overseas parameters】: DEVICEINFO_IPHONE_TOKEN(必填)【required】")] + public string iOSOS_DEVICEINFO_IPHONE_TOKEN; + + // [SerializeField] + // [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "成功十次【Level complete 10 times】", + //"", false, "海外参数【Overseas parameters】: PLAY_10_TOKEN(必填)【required】")] + // public string iOSOS_PLAY_10_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "插屏展示【IV ad shows】", + "", false, "海外参数【Overseas parameters】: INTERSITIAL_SHOW_COUNT_TOKEN(必填)【required】")] + public string iOSOS_INTERSITIAL_SHOW_COUNT_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "次日启动【Reopen app on the next day】", + "", false, "海外参数【Overseas parameters】: SECOND_LAUNCH_DAY_TOKEN(必填)【required】")] + public string iOSOS_SECOND_LAUNCH_DAY_TOKEN; + + // [SerializeField] + // [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "游戏次数【Game played time】", + //"", false, "海外参数【Overseas parameters】: GAME_FINISH(必填)【required】")] + // public string iOSOS_GAME_FINISH; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "激励视频展示【RV ad shows】", + "", false, "海外参数【Overseas parameters】: VIDEO_SHOW_COUNT_TOKEN(必填)【required】")] + public string iOSOS_VIDEO_SHOW_COUNT_TOKEN; + + // [SerializeField] + // [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "视频+插屏上报【IV+RV ad showed report】", + //"", false, "海外参数【Overseas parameters】: VIDEO_AND_INTERITIAL_COUNT_TOKEN(必填)【required】")] + // public string iOSOS_VIDEO_AND_INTERITIAL_COUNT_TOKEN; + + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "评价主动弹出事件token【AppStore rating window pops up report】", + // "", false, "海外参数【Overseas parameters】: FIRST_RATE_TOKEN(必填)【required】")] + //public string iOSOS_FIRST_RATE_TOKEN; + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "累计N次RVIV视频【RV+IV ad showed X time】", +"", false, "海外参数【Overseas parameters】: ADJUST_EVENT_RVIV24(必填)【required】")] + public string iOSOS_ADJUST_EVENT_RVIV24; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "累计N次RV视频【RV ad showed X time】", + "", false, "海外参数【Overseas parameters】: ADJUST_EVENT_RV24(必填)【required】")] + public string iOSOS_ADJUST_EVENT_RV24; + + #endregion + + #endregion + + + #region APPLE_APP_ID-------------CN + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.JoyPacSetting, "APPLE_APP_ID", "", + true, "国内参数【Domestic parameters】: 是否有评价弹出功能 \n【Whether there is a evaluation popup function】")] + public bool iOSCN_IsHaveAppraise; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.JoyPacSetting, "APPLE_APP_ID", "", + false, "国内参数【Domestic parameters】: 苹果后台APP_ID 主要用于评价弹出网址 \n【Apple background APP_ID is used to evaluate pop-up urls】")] + public string iOSCN_APPLE_APP_ID; + + #endregion + + #region APPLE_APP_ID-------------OS + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "APPLE_APP_ID", "", + true, "海外参数【Overseas parameters】:是否有评价弹出功能\n【Whether there is a evaluation popup function】")] + public bool iOSOS_IsHaveAppraise; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.JoyPacSetting, "APPLE_APP_ID", "", + false, "海外参数【Overseas parameters】:苹果后台APP_ID 主要用于评价弹出网址\n【Apple background APP_ID is used to evaluate pop-up urls】")] + public string iOSOS_APPLE_APP_ID; + + #endregion + + #region iOS_JoyPacAd--------------CN + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdParams, "JoypacAppName", "", + false, "国内参数【Domestic parameters】: 产品提供(必填)【required】【fill in providing by product team(required)")] + public string iOSCN_JoypacAppName; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdParams, "JOYPAC_SDK_APPID", + "", false, "国内参数【Domestic parameters】: 产品提供(必填)【required】【fill in providing by product team(required)")] + public string iOSCN_JOYPAC_SDK_APPID; + + + + + #endregion + + + + + #region 实名制+隐私+合规-------------CN + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Pop_Up, "PrivacyURL", "PrivacyURL", + true, "国内参数【Domestic parameters】: 隐私链接 \n【PrivacyURL】")] + public string iOSCN_PrivacyURL; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Pop_Up, "ProtocolURL", "ProtocolURL", + false, "国内参数【Domestic parameters】: 用户协议 \n【ProtocolURL】")] + public string iOSCN_ProtocolURL; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Pop_Up, "GameName", "GameName", + false, "国内参数【Domestic parameters】: 游戏名字(合规弹框) \n【GameName(Compliance bounced)】")] + public string iOSCN_GameName; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Pop_Up, "GameType", "GameType", + false, "国内参数【Domestic parameters】: 游戏类型(合规弹框) \n【GameType(Compliance bounced)】")] + public string iOSCN_GameType; + + #endregion + + + + #region 实名制+隐私+合规-------------OS 因为不写可能会崩溃,怕万一后台配置错误,所以这里给个默认的值 + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Pop_Up, "PrivacyURL", "PrivacyURL", + // true, "国内参数【Domestic parameters】: 隐私链接 \n【PrivacyURL】")] + //public string iOSOS_PrivacyURL = "https://joypacgames.com/zh-hant/privacy-policy/"; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Pop_Up, "ProtocolURL", "ProtocolURL", + // false, "国内参数【Domestic parameters】: 用户协议 \n【ProtocolURL】")] + //public string iOSOS_ProtocolURL = "https://joypacgames.com/zh-hant/terms-conditions/"; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Pop_Up, "GameName", "GameName", + // false, "国内参数【Domestic parameters】: 游戏名字(合规弹框) \n【GameName(Compliance bounced)】")] + //public string iOSOS_GameName = "GameName"; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Pop_Up, "GameType", "GameType", + // false, "国内参数【Domestic parameters】: 游戏类型(合规弹框) \n【GameType(Compliance bounced)】")] + //public string iOSOS_GameType = "GameType"; + + #endregion + + #region iOS_JoyPacAd--------------OS + [SerializeField] + + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdParams, "JoypacAppName", "", + false, "海外参数【Overseas parameters】: 产品提供(必填)【required】【fill in providing by product team(required)")] + public string iOSOS_JoypacAppName; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdParams, "JOYPAC_SDK_APPID", + "", false, "海外参数【Overseas parameters】: 产品提供(必填)【required】【fill in providing by product team(required)")] + public string iOSOS_JOYPAC_SDK_APPID; + + + + #endregion + + + + #region iOS友盟--------------CN + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Umeng, "UMENG_APPKEY", "", + false, "国内参数【Domestic parameters】: UMENG_APPKEY(必填)【required】")] + public string iOSCN_UMENG_APPKEY; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Umeng, "UMENG_CHANNELID", + "", false, "国内参数【Domestic parameters】: UMENG_CHANNELID(必填)【required】")] + public string iOSCN_UMENG_CHANNELID = "AppStore"; + + + + #endregion + + + + #region iOS友盟--------------OS + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Umeng, "UMENG_APPKEY", "", + false, "海外参数【Overseas parameters】: UMENG_APPKEY(必填)【required】")] + public string iOSOS_UMENG_APPKEY; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.Umeng, "UMENG_CHANNELID", + "", false, "海外参数【Overseas parameters】: UMENG_CHANNELID(必填)【required】")] + public string iOSOS_UMENG_CHANNELID = "AppStore"; + + #endregion + + + + + #region Att弹框 + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.Editor, JPEditorComponentType.Att, "iOS_IsAttEnabled", + "AttEnabled", false)] + public bool AttEnabled = false; + + #endregion + + #region iOS-Ad--------------CN + + + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Admob", + // "", true, "国内平台: Admob")] + //public bool iOSCN_Admob = true; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, + "iOS_Admob_GADApplicationIdentifier", "GADApplicationIdentifier", + false, "国内平台: Admob 的 Appid 参数(必填)")] + public string iOSCN_Admob_GADApplicationIdentifier; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_IronSource", + // null, false, "国内平台: IronSource")] + //public bool iOSCN_IronSource = true; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_GDT", + // "", false, "国内平台: 广点通")] + //public bool iOSCN_GDT = true; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_UnityAd", + // "", false, "国内平台: Unity")] + //public bool iOSCN_UnityAd = true; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Vungle", + // null, false, "国内平台: Vungle")] + //public bool iOSCN_Vungle = true; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_KS", + // null, false, "国内平台: 快手(测试阶段不需要)")] + //public bool iOSCN_KS = false; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Pangle_China", + // null, false, "国内平台: pangle(测试阶段不需要)")] + //public bool iOSCN_Pangle_China = false; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Applovin", + // null, true, "国内平台: Applovin(测试阶段不需要)")] + //public bool iOSCN_Applovin = false; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, + "iOS_AppLovinSdkKey", "AppLovinSdkKey", + false, "国内平台: AppLovin 的 SdkKey 参数(必填)")] + public string iOSCN_AppLovinSdkKey; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_KlevinSDK", + // null, true, "国内平台: 游可赢(测试阶段不需要)")] + //public bool iOSCN_KlevinSDK = false; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Adcolony", + // null, false, "国内平台: Adcolony(国内不需要)")] + //public bool iOSCN_Adcolony = false; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Maio", + // null, false, "国内平台: Maio(国内不需要)")] + //public bool iOSCN_Maio = false; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Chartboost", + // null, false, "国内平台: Chartboost(国内不需要)")] + //public bool iOSCN_Chartboost = false; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Facebook", + // null, false, "国内平台: FaceBook(国内不需要)")] + //public bool iOSCN_FaceBook = false; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.AdNet, "iOS_Fyber", + // null, false, "国内平台: Fyber(国内不需要)")] + //public bool iOSCN_Fyber = false; + + #endregion + + #region iOS-Ad--------------OS + + + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Admob", + // "", true, "海外平台: Admob")] + //public bool iOSOS_Admob = true; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, + "iOS_Admob_GADApplicationIdentifier", "GADApplicationIdentifier", + false, "海外平台: Admob 的 Appid 参数(必填)")] + public string iOSOS_Admob_GADApplicationIdentifier; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_IronSource", + // null, false, "海外平台: IronSource")] + //public bool iOSOS_IronSource = true; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_GDT", + // "", false, "海外平台: 广点通")] + //public bool iOSOS_GDT = true; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_UnityAd", + // "", false, "海外平台: Unity")] + //public bool iOSOS_UnityAd = true; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Vungle", + // null, false, "海外平台: Vungle")] + //public bool iOSOS_Vungle = true; + + + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Adcolony", + // null, false, "海外平台: Adcolony(测试阶段不需要)")] + //public bool iOSOS_Adcolony = false; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Maio", + // null, false, "国内平台: Maio(测试阶段不需要)")] + //public bool iOSOS_Maio = false; + + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Chartboost", + // null, false, "海外平台: Chartboost(测试阶段不需要)")] + //public bool iOSOS_Chartboost = false; + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Facebook", + // null, false, "海外平台: FaceBook(测试阶段不需要)")] + //public bool iOSOS_FaceBook = false; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Fyber", + // null, false, "海外平台: Fyber(测试阶段不需要)")] + //public bool iOSOS_Fyber = false; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Pangle_nonChina", + // null, false, "海外平台: Pangle(测试阶段不需要)")] + //public bool iOSOS_Pangle_nonChina = false; + + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_Applovin", + // null, true, "海外平台: Applovin(测试阶段不需要)")] + //public bool iOSOS_Applovin = false; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, + "iOS_AppLovinSdkKey", "AppLovinSdkKey", + false, "海外平台: AppLovin 的 SdkKey 参数")] + public string iOSOS_AppLovinSdkKey; + + + + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_KS", + // null, false, "海外平台: 快手(海外不需要)")] + //public bool iOSOS_KS = false; + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, "iOS_KlevinSDK", + // null, true, "海外平台: 游可赢(海外不需要)")] + //public bool iOSOS_KlevinSDK = false; + + #endregion + + + #region Push + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.iOS, JPReleaseAreaType.CN, JPEditorComponentType.Push, "iOS_IsPushEnabled", + "PushEnabled", false, "国内参数【Domestic parameters】: 是否默认启用 Push 功能")] + public bool PushEnabled; + + #endregion + + #endregion + + + #region Android + + + #region Android-Ga-Adjust + + + + #region Android-Ga-Adjust-------OS + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "AdjustDeeplink", "", + false, "海外参数【Overseas parameters】: AdjustDeeplink(非必填)")] + public string AndroidOS_AdjustDeeplink; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "ADJUST_APP_TOKEN", + "", false, "海外参数【Overseas parameters】: ADJUST_APP_TOKEN(必填)【required】")] + public string AndroidOS_ADJUST_APP_TOKEN; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "GA_GAME KEY", + "", false, "海外参数【Overseas parameters】: GA_GAME KEY(必填)【required】")] + public string AndroidOS_GA_gameKey; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "GA_SECRET KEY", + "", false, "海外参数【Overseas parameters】: GA_SECRET KEY(必填)【required】")] + public string AndroidOS_GA_secretKey; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Ga_Adjust, "IsHaveAdjustEvent", + "", true, "请选择 是否有adjust事件【IsHaveAdjustEvent parameter】(必填)【required】")] + public bool AndroidOS_IsHaveAdjustEvent; + + + #region Android adjust Event + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "判断当前设备是ipad的事件token【Device model is iPad】", + "", false, "海外参数【Overseas parameters】: DEVICEINFO_IPAD_TOKEN(必填)【required】")] + public string AndroidOS_DEVICEINFO_IPAD_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "判断当前设备是iphone的事件token【Device model is iphone】", + "", false, "海外参数【Overseas parameters】: DEVICEINFO_IPHONE_TOKEN(必填)【required】")] + public string AndroidOS_DEVICEINFO_IPHONE_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "插屏展示【IV ad shows】", + "", false, "海外参数【Overseas parameters】: INTERSITIAL_SHOW_COUNT_TOKEN(必填)【required】")] + public string AndroidOS_INTERSITIAL_SHOW_COUNT_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "次日启动【Reopen app on the next day】", + "", false, "海外参数【Overseas parameters】: SECOND_LAUNCH_DAY_TOKEN(必填)【required】")] + public string AndroidOS_SECOND_LAUNCH_DAY_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "激励视频展示【RV ad shows】", + "", false, "海外参数【Overseas parameters】: VIDEO_SHOW_COUNT_TOKEN(必填)【required】")] + public string AndroidOS_VIDEO_SHOW_COUNT_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "累计N次RVIV视频【RV+IV ad showed X time】", +"", false, "海外参数【Overseas parameters】: ADJUST_EVENT_RVIV24(必填)【required】")] + public string AndroidOS_ADJUST_EVENT_RVIV24; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdjustEvent, "累计N次RV视频【RV ad showed X time】", + "", false, "海外参数【Overseas parameters】: ADJUST_EVENT_RV24(必填)【required】")] + public string AndroidOS_ADJUST_EVENT_RV24; + + #endregion + + #endregion + + + #region Android-Ga-Adjust-------CN + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "AdjustDeeplink", "", + false, "国内参数【Domestic parameters】: AdjustDeeplink(非必填)")] + public string AndroidCN_AdjustDeeplink; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "ADJUST_APP_TOKEN", + "", false, "国内参数【Domestic parameters】: ADJUST_APP_TOKEN(必填)【required】")] + public string AndroidCN_ADJUST_APP_TOKEN; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "GA_GAME KEY", + "", false, "国内参数【Domestic parameters】: GA_GAME KEY(必填)【required】")] + public string AndroidCN_GA_gameKey; + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "GA_SECRET KEY", + "", false, "国内参数【Domestic parameters】: GA_SECRET KEY(必填)【required】")] + public string AndroidCN_GA_secretKey; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.Ga_Adjust, "IsHaveAdjustEvent", + "", true, "请选择 是否有adjust事件【IsHaveAdjustEvent parameter】(必填)【required】")] + public bool AndroidCN_IsHaveAdjustEvent; + + + #region Android adjust Event + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "判断当前设备是ipad的事件token【Device model is iPad】", + "", false, "国内参数【Domestic parameters】: DEVICEINFO_IPAD_TOKEN(必填)【required】")] + public string AndroidCN_DEVICEINFO_IPAD_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "判断当前设备是iphone的事件token【Device model is iphone】", + "", false, "国内参数【Domestic parameters】: DEVICEINFO_IPHONE_TOKEN(必填)【required】")] + public string AndroidCN_DEVICEINFO_IPHONE_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "插屏展示【IV ad shows】", + "", false, "国内参数【Domestic parameters】: INTERSITIAL_SHOW_COUNT_TOKEN(必填)【required】")] + public string AndroidCN_INTERSITIAL_SHOW_COUNT_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "次日启动【Reopen app on the next day】", + "", false, "国内参数【Domestic parameters】: SECOND_LAUNCH_DAY_TOKEN(必填)【required】")] + public string AndroidCN_SECOND_LAUNCH_DAY_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "激励视频展示【RV ad shows】", + "", false, "国内参数【Domestic parameters】: VIDEO_SHOW_COUNT_TOKEN(必填)【required】")] + public string AndroidCN_VIDEO_SHOW_COUNT_TOKEN; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "累计N次RVIV视频【RV+IV ad showed X time】", +"", false, "国内参数【Domestic parameters】: ADJUST_EVENT_RVIV24(必填)【required】")] + public string AndroidCN_ADJUST_EVENT_RVIV24; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdjustEvent, "累计N次RV视频【RV ad showed X time】", + "", false, "国内参数【Domestic parameters】: ADJUST_EVENT_RV24(必填)【required】")] + public string AndroidCN_ADJUST_EVENT_RV24; + + #endregion + + #endregion + + + #region Android_JoyPacAd--------------OS + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdParams, "JoypacAppName", "", + false, "海外参数【Overseas parameters】: JoypacAppName(必填)【required】【required】产品提供,注意此参数更新后需手动更新Properties文件【After this parameter is updated, you need to manually update the Properties file】")] + public string AndroidOS_JoypacAppName; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdParams, "JOYPAC_SDK_APPID", + "", false, "海外参数【Overseas parameters】: JOYPAC_SDK_APPID(必填)【required】,注意此参数更新后需手动更新Properties文件【After this parameter is updated, you need to manually update the Properties file】")] + public string AndroidOS_JOYPAC_SDK_APPID; + + #endregion + + #region Android_JoyPacAd--------------CN + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdParams, "JoypacAppName", "", + false, "国内参数【Domestic parameters】: JoypacAppName(必填)【required】【required】产品提供")] + public string AndroidCN_JoypacAppName; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.CN, JPEditorComponentType.AdParams, "JOYPAC_SDK_APPID", + "", false, "国内参数【Domestic parameters】: JOYPAC_SDK_APPID(必填)【required】,注意此参数更新后需手动更新Properties文件【After this parameter is updated, you need to manually update the Properties file】")] + public string AndroidCN_JOYPAC_SDK_APPID; + + #endregion + + #region Android友盟--------------OS + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Umeng, "UMENG_APPKEY", "", + false, "国内参数【Domestic parameters】: UMENG_APPKEY(必填)【required】,注意此参数更新后需手动更新Properties文件【After this parameter is updated, you need to manually update the Properties file】")] + public string AndroidOS_UMENG_APPKEY; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Umeng, "UMENG_CHANNELID", + "", false, "国内参数【Domestic parameters】: UMENG_CHANNELID(必填)【required】")] + public string AndroidOS_UMENG_CHANNELID = "googleplay"; + + #endregion + + #region Android Ad--------------OS + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdNet, + "Android_Admob_GADApplicationIdentifier", "com.google.android.gms.ads.APPLICATIO", + false, "海外平台: Admob 的 Appid 参数(必填)")] + public string AndroidOS_Admob_GADApplicationIdentifier; + #endregion + + + + #region Android_properties--------------OS + //[SerializeField] + //[InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Properties, "默认参数,一般无需更改", "", + // false, "海外参数【Overseas parameters】:(不需要填有默认值 默认值\n【Default value is not required. Default value】:com.unity3d.player.UnityPlayerActivity )")] + //public string base_game_main_activity_class_name = "com.unity3d.player.UnityPlayerActivity"; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Properties, "GAME NAME", +"", false, "海外参数【Overseas parameters】: joypac参数 产品提供(必填)【required】\n【fill in providing by product team(required)")] + public string app_setting_name; + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Properties, "app_settting_def_key", "", + false, "海外参数【Overseas parameters】:产品提供(必填)【required】\n【fill in providing by product team(required)】")] + public string app_settting_def_key; + + + [SerializeField] + [InspectorGameParams(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Properties, Properties.splash_orientation_key, +"", false, "海外参数横竖屏: 竖屏填 1 横屏填 2 (必填)【required】\n 【Horizontal and vertical screen: 1 vertical screen: 2 horizontal screen (required)】")] + public string splash_orientation_key; + + + #endregion + #endregion + #endregion + + + // 登录类型 + public enum LoginMode : int + { + // 不接入sdk登录login + NO_LOGIN = -1, + + // 静默登录 + SILENT_LOGIN = 1, + + // 弹窗登录 + WINDOW_LOGIN = 2, + } + + // Android平台危险权限列表 + public enum AndroidDangerousPermissions + { + // 允许程序读取用户日历数据 + READ_CALENDAR, + + // 允许一个程序写入但不读取用户日历数据 + WRITE_CALENDAR, + + // 允许访问摄像头进行拍照 + CAMERA, + + // 允许程序读取用户联系人数据 + READ_CONTACTS, + + // 允许程序写入但不读取用户联系人数据 + WRITE_CONTACTS, + + // 访问一个帐户列表在Accounts Service中 + GET_ACCOUNTS, + + // 允许一个程序访问精良位置(如GPS) + ACCESS_FINE_LOCATION, + + // 允许一个程序访问CellID或WiFi热点来获取粗略的位置 + ACCESS_COARSE_LOCATION, + + // 允许程序录制音频 + RECORD_AUDIO, + + // 允许一个程序初始化一个电话拨号不需通过拨号用户界面需要用户确认 + READ_PHONE_STATE, + + // 访问电话状态 + CALL_PHONE, + + // 查看电话日志 + READ_CALL_LOG, + + // 写入电话日志 + WRITE_CALL_LOG, + + // 允许应用程序添加系统中的语音邮件 + ADD_VOICEMAIL, + + // 允许程序使用SIP视频服务 + USE_SIP, + + // 允许应用程序监视、修改、忽略拨出的电话 + PROCESS_OUTGOING_CALLS, + + // 允许该应用存取监测您身体状况的传感器所收集的数据,例如您的心率 + BODY_SENSORS, + + // 允许程序发送SMS短信 + SEND_SMS, + + // 允许程序监控一个将收到短信息,记录或处理 + RECEIVE_SMS, + + // 允许程序读取短信息 + READ_SMS, + + // 允许程序监控将收到WAP PUSH信息 + RECEIVE_WAP_PUSH, + + // 允许一个程序监控将收到MMS彩信,记录或处理 + RECEIVE_MMS, + + // 允许程序写入外部存储,如SD卡上写文件 + READ_EXTERNAL_STORAGE, + + // 访问您设备上的照片、媒体内容和文件 + WRITE_EXTERNAL_STORAGE, + + // 空权限 + NONE, + } + + // 游戏适龄等级 无限制,8+,12+,16+ + public enum AgeLevelOfTheGame + { + NO_LIMIT = 0, + AGE_8_AND_ABOVE = 8, + AGE_12_AND_ABOVE = 12, + AGE_16_AND_ABOVE = 16, + } +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParams.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParams.cs.meta new file mode 100644 index 00000000..603257a7 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParams.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: edf2b10a78afa4801a0ccced23ab711d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParamsManager.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParamsManager.cs new file mode 100644 index 00000000..48bc54c9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParamsManager.cs @@ -0,0 +1,988 @@ +#if UNITY_EDITOR +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Linq.Expressions; +using System.Reflection; +using System.Text.RegularExpressions; +using System.Xml; +using UnityEditor; +using UnityEditor.iOS.Xcode; +using UnityEngine; +public static class JoyPacParamsManager +{ + // 通过组件类型获取字段信息列表 + public static IEnumerable GetInitParamsFieldInfoByComponentType( + JPEditorPlatformType platformType, JPReleaseAreaType releasePlatformType, + JPEditorComponentType componentType) + { + var fieldInfos = new List(); + foreach (var fieldInfo in InitParamsValidFieldInfo) + { + var attr = GetInitFieldAttr(fieldInfo); + + if (attr.PlatformType == platformType && attr.ReleasePlatformType == releasePlatformType && attr.ComponentType == componentType) + { + + fieldInfos.Add(fieldInfo); + } + } + + return fieldInfos; + } + + + + + // 通过平台类型,获取构建参数字段信息 + public static IEnumerable GetBuildParamsFieldInfoByPlatformType(JPEditorPlatformType platformType, JPReleaseAreaType releasePlatformType, JPEditorComponentType componentType) + { + var fieldInfos = new List(); + foreach (var fieldInfo in BuildParamsFieldInfo) + { + var attr = GetInitFieldAttr(fieldInfo); + if (attr.PlatformType == platformType && attr.ReleasePlatformType == releasePlatformType && attr.ComponentType == componentType) + { + fieldInfos.Add(fieldInfo); + } + } + + return fieldInfos; + } + + // 初始化参数中所有有效的字段信息「有效字段信息代表」加了特定注解的成员变量 + private static IEnumerable InitParamsValidFieldInfo + { + get + { + return AutomationManager.GetValidFieldInfo(AutomationManager + .JoyPacParams.GetType()); + } + } + + + // 构建参数中有效的字段信息,加了特定注解的成员变量 + private static IEnumerable BuildParamsFieldInfo + { + get + { + return + AutomationManager.GetValidFieldInfo(AutomationManager + .JoyPacBuildParams.GetType()); + } + } + + // 通过字段名获取初始化信息 + public static InspectorGameParamsAttribute GetInitAttrByFieldName(string fieldName) + { + return (from fieldInfo in InitParamsValidFieldInfo + where fieldName == fieldInfo.Name + select GetInitFieldAttr(fieldInfo)).FirstOrDefault(); + } + + // 获取初始化字段中的自定义注解 + public static InspectorGameParamsAttribute GetInitFieldAttr(FieldInfo fieldInfo) + { + return AutomationManager.GetAttr(fieldInfo); + } + + + /// + /// 字段值被修改后调用的方法. + /// + /// 字段名称. + /// 修改后的值. + /// + public static void FieldValueChange(string fieldName, object value) + { + + RefreshPrefabValue(fieldName, value); + + AssetDatabase.Refresh(); + + } + + /// + /// 刷新prefab中保存的值. + /// + /// 字段名称. + /// 修改后的值. + private static void RefreshPrefabValue(string fieldName, object value) + { + var JoyPacParams = AutomationManager.JoyPacParams; + RefreshFieldValue(JoyPacParams, fieldName, value); + EditorUtility.SetDirty(JoyPacParams); + AssetDatabase.SaveAssets(); + AssetDatabase.Refresh(); + GetJPReleaseAreaType(); + UpdateStringKey(); + } + + + /// + /// 刷新目标对象中字段的值. + /// + /// 目标对象. + /// 字段名. + /// 字段值. + private static void RefreshFieldValue(T obj, string fieldName, object value) + { + var fieldInfo = GetFieldInfo(obj, fieldName); + if (fieldInfo != null) + { + fieldInfo.SetValue(obj, value); + } + } + + /// + /// 获取字段信息. + /// + /// 目标对象. + /// 字段名称. + /// 字段信息. + private static FieldInfo GetFieldInfo(T t, string fieldName) + { + if (t == null) + { + LogTool.DebugLog("target object is null."); + return null; + } + + if (string.IsNullOrEmpty(fieldName)) + { + LogTool.DebugLog(t.GetType() + " is null."); + return null; + } + + var type = t.GetType(); + var myFieldInfo = type.GetField(fieldName); + return myFieldInfo; + } + + +#if UNITY_IOS + public static int RemoveCount = 6; +#elif UNITY_ANDROID + public static int RemoveCount = 10; +#endif + + + + public static JPReleaseAreaType GetJPReleaseAreaType() + { + +#if UNITY_IOS + IEnumerable attFieldInfos = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, JPReleaseAreaType.Editor, JPEditorComponentType.Core); +#elif UNITY_ANDROID + IEnumerable attFieldInfos = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, JPReleaseAreaType.Editor, JPEditorComponentType.Core); +#elif UNITY_EDITOR + IEnumerable attFieldInfos = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Editor, JPReleaseAreaType.Editor, JPEditorComponentType.Core); +#endif + foreach (var info in attFieldInfos) + { + if (info.FieldType == typeof(JPReleaseAreaType)) + return (JPReleaseAreaType)info.GetValue(AutomationManager.JoyPacParams); + } + + return JPReleaseAreaType.Editor; + + } + + + +#if UNITY_IOS + /// + /// 是否需要att弹框 + /// + + public static bool isAttEnable() + { + + IEnumerable attFieldInfos = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, JPReleaseAreaType.Editor, JPEditorComponentType.Att); + foreach (var info in attFieldInfos) + { + if (info.FieldType == typeof(bool)) + return (bool)info.GetValue(AutomationManager.JoyPacParams); + } + return false; + + } + + #region bundle处理 + public static string[] WriteBundlePath() + { + List strList = new List(); + string adPath = "JoyPacSDK/JoyPacAd/JoyPacAd/Plugins/iOS/"; + + JPReleaseAreaType jPReleaseAreaType = GetJPReleaseAreaType(); + if (JPPackageManager.HasComponent(JPComponenetType.Umeng)) + { + strList.Add("JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle"); + } + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd)) + { + string jp = adPath + "JPSDK/JPSDK.bundle"; + + string MS = adPath + "JPSDK/MSAntiAddiction.bundle"; + string MSH = adPath + "JPSDK/MSAntiAddictionH.bundle"; + strList.Add(jp); + strList.Add(MS); + strList.Add(MSH); + string core = adPath + "Core/JoyPacSDK.bundle"; + + //pangle + switch (jPReleaseAreaType) + { + case JPReleaseAreaType.CN: + strList.Add(adPath + "Third/pangle_China/BUAdSDK.bundle"); + break; + + case JPReleaseAreaType.OS: + strList.Add(adPath + "Third/pangle_nonChina/BUAdSDK.bundle"); + break; + } + + strList.Add(core); + + strList.Add(adPath + "Third/applovin/AppLovinSDKResources.bundle"); + strList.Add(adPath + "Third/sigmob/Sigmob.bundle"); + strList.Add(adPath + "Third/fyber/IASDKCore/IASDKResources.bundle"); + } + string[] str = strList.ToArray(); + return str; + } + #endregion + + + public static string[] EmbedFrameworks() + { + List strList = new List(); + string adPath = "JoyPacSDK/JoyPacAd/JoyPacAd/Plugins/iOS/Third/"; + + JPReleaseAreaType jPReleaseAreaType = GetJPReleaseAreaType(); + + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd)) + { + //strList.Add(adPath + "facebook/FBSDKCoreKit.framework"); + //strList.Add(adPath + "facebook/FBBiddingKit.framework"); + strList.Add(adPath + "kuaishou/KSAdSDK.framework"); + + + } + string[] str = strList.ToArray(); + return str; + } + + + + + + public static bool isHasComponentJoyPacAd() + { + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd)) + return true; + else return false; + } + + + public static void WriteInitParamsToXcodePlist(PlistDocument plist) + { + + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd)) + { + IEnumerable adFieldInfos = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, GetJPReleaseAreaType(), JPEditorComponentType.AdNet); + foreach (var info in adFieldInfos) + { + iOSHandleAdnRoi测试ParamsToPlist(plist, info); + iOSHandleAdn正式发行ParamsToPlist(plist, info); + } + + } + + if (GetJPReleaseAreaType() == JPReleaseAreaType.CN) + { + IEnumerable popFieldInfos = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, GetJPReleaseAreaType(), JPEditorComponentType.Pop_Up); + + foreach (var info in popFieldInfos) + { + iOSHandle弹框(plist, info); + } + } + else + { + Debug.Log("plist.root"); + plist.root.SetString("PrivacyURL", "https://joypacgames.com/zh-hant/privacy-policy/"); + plist.root.SetString("ProtocolURL", "https://joypacgames.com/zh-hant/terms-conditions/"); + plist.root.SetString("GameName", "GameName"); + plist.root.SetString("GameType", "GameType"); + } + + + } + + private static void iOSHandleAdnRoi测试ParamsToPlist(PlistDocument plist, FieldInfo fieldInfo) + { + var attr = GetInitFieldAttr(fieldInfo); + if (fieldInfo.FieldType == typeof(string)) + { + string jsonKey = fieldInfo.Name.Remove(3, 2); + Debug.Log(jsonKey); + // AdMob参数单独处理. + if (jsonKey == "iOS_Admob_GADApplicationIdentifier") + { + + if (string.IsNullOrEmpty((string)fieldInfo.GetValue(AutomationManager.JoyPacParams))) + { + Debug.LogError(attr.TargetPlatformParameterKey + "为空,请填写正确值"); + } + + + + plist.root.SetString(attr.TargetPlatformParameterKey, + (string)fieldInfo.GetValue(AutomationManager.JoyPacParams)); + plist.root.SetBoolean("GADIsAdManagerApp", true); + + } + + } + + } + private static void iOSHandleAdn正式发行ParamsToPlist(PlistDocument plist, FieldInfo fieldInfo) + { + var attr = GetInitFieldAttr(fieldInfo); + if (fieldInfo.FieldType == typeof(string)) + { + string jsonKey = fieldInfo.Name.Remove(3, 2); + //applovin + if (jsonKey == "iOS_AppLovinSdkKey") + { + + if (string.IsNullOrEmpty((string)fieldInfo.GetValue(AutomationManager.JoyPacParams))) + { + Debug.LogError(attr.TargetPlatformParameterKey + "为空,请填写正确值"); + + } + + + plist.root.SetString(attr.TargetPlatformParameterKey, + (string)fieldInfo.GetValue(AutomationManager.JoyPacParams)); + + } + } + } + + + private static void iOSHandle弹框(PlistDocument plist, FieldInfo fieldInfo) + { + + var attr = GetInitFieldAttr(fieldInfo); + if (fieldInfo.FieldType == typeof(string)) + { + string jsonKey = fieldInfo.Name.Remove(3, 2); + + if (jsonKey == "iOS_PrivacyURL") + { + + if (string.IsNullOrEmpty((string)fieldInfo.GetValue(AutomationManager.JoyPacParams))) + { + Debug.LogError(attr.TargetPlatformParameterKey + "为空,请填写正确值"); + + } + + + plist.root.SetString(attr.TargetPlatformParameterKey, + (string)fieldInfo.GetValue(AutomationManager.JoyPacParams)); + + } + + if (jsonKey == "iOS_ProtocolURL") + { + + if (string.IsNullOrEmpty((string)fieldInfo.GetValue(AutomationManager.JoyPacParams))) + { + Debug.LogError(attr.TargetPlatformParameterKey + "为空,请填写正确值"); + + } + + + plist.root.SetString(attr.TargetPlatformParameterKey, + (string)fieldInfo.GetValue(AutomationManager.JoyPacParams)); + + } + if (jsonKey == "iOS_GameName") + { + + if (string.IsNullOrEmpty((string)fieldInfo.GetValue(AutomationManager.JoyPacParams))) + { + Debug.LogError(attr.TargetPlatformParameterKey + "为空,请填写正确值"); + + } + + + plist.root.SetString(attr.TargetPlatformParameterKey, + (string)fieldInfo.GetValue(AutomationManager.JoyPacParams)); + + } + if (jsonKey == "iOS_GameType") + { + + if (string.IsNullOrEmpty((string)fieldInfo.GetValue(AutomationManager.JoyPacParams))) + { + Debug.LogError(attr.TargetPlatformParameterKey + "为空,请填写正确值"); + + } + + + plist.root.SetString(attr.TargetPlatformParameterKey, + (string)fieldInfo.GetValue(AutomationManager.JoyPacParams)); + + } + } + + + } + +#endif + +#if UNITY_ANDROID + + public static List AllPath = new List(); + + private const string ManifestApplicationAdmobTag = "com.google.android.gms.ads.APPLICATION_ID"; + private const string ManifestApplicationUmengTag = "UMENG_APPKEY"; + + [MenuItem("JoyPacSDK/更新AndroidManifest参数文件(Update the AndroidManifest file)")] + private static void WriteXmlKey() + { + WriteXmlKey("", ""); + } + + + private static bool PackingInspection() + { + return false; + } + + private static void SetAdmobAppID(XmlDocument manifest, XmlNode applicationNode) + { + IEnumerable adFieldInfo正式发行 = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.AdNet); + + foreach (var info in adFieldInfo正式发行) + { + var attr = GetInitFieldAttr(info); + + if (info.FieldType == typeof(string)) + { + string jsonKey = info.Name.Remove(7, 2); + + if (jsonKey == "Android_Admob_GADApplicationIdentifier") + { + if (string.IsNullOrEmpty((string)info.GetValue(AutomationManager.JoyPacParams))) + { + Debug.LogError("[JoyPacSDK]:" + attr.TargetPlatformParameterKey + "为空,请填写正确值"); + + } + + XmlElement element_APPLICATIO = manifest.CreateElement("meta-data"); + element_APPLICATIO.SetAttribute("android_name", ManifestApplicationAdmobTag); + element_APPLICATIO.SetAttribute("android_value", (string)info.GetValue(AutomationManager.JoyPacParams)); + element_APPLICATIO.SetAttribute("tools_replace", "android:value"); + applicationNode.AppendChild(element_APPLICATIO); + Debug.Log("[JoyPacSDK]: ,更新AndroidManifest文件中 【Android_Admob_GADApplicationIdentifier】参数 参数更新为" + (string)info.GetValue(AutomationManager.JoyPacParams)); + } + + } + + } + + + } + + private static void SetUmengAppKey(XmlDocument manifest, XmlNode applicationNode) + { + IEnumerable PrFieldInfo正式发行 = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Umeng); + + foreach (var info in PrFieldInfo正式发行) + { + var attr = GetInitFieldAttr(info); + + if (info.FieldType == typeof(string)) + { + if (info.Name == "AndroidOS_UMENG_APPKEY") + { + if (string.IsNullOrEmpty((string)info.GetValue(AutomationManager.JoyPacParams))) + { + Debug.LogError("[JoyPacSDK]:" + attr.TargetPlatformParameterKey + "为空,请填写正确值"); + + } + XmlElement element_APPLICATIO = manifest.CreateElement("meta-data"); + element_APPLICATIO.SetAttribute("android_name", ManifestApplicationUmengTag); + element_APPLICATIO.SetAttribute("android_value", (string)info.GetValue(AutomationManager.JoyPacParams)); + applicationNode.AppendChild(element_APPLICATIO); + Debug.Log("[JoyPacSDK]: 更新AndroidManifest文件中 【umeng_appkey】参数 参数更新为: " + (string)info.GetValue(AutomationManager.JoyPacParams)); + + + } + + } + + } + + + } + + private static XmlDocument ManifestFile() + { + string appManifestPath = Path.Combine(Application.dataPath, "Plugins/Android/AndroidManifest.xml"); + XmlDocument manifestFile = new XmlDocument(); + manifestFile.Load(appManifestPath); + return manifestFile; + + } + + private static XmlNode ApplicationNode(XmlDocument manifestFile) + { + + XmlElement manifestRoot = manifestFile.DocumentElement; + XmlNode applicationNode = null; + foreach (XmlNode node in manifestRoot.ChildNodes) + { + if (node.Name == "application") + { + applicationNode = node; + break; + } + } + return applicationNode; + + } + + public static void WriteXmlKey(string fieldName, object value) + { + + + string appManifestPath = Path.Combine(Application.dataPath, "Plugins/Android/AndroidManifest.xml"); + string androidPluginsPath = Path.Combine(Application.dataPath, "Plugins/Android"); + string JoyPacManifestPath = Path.Combine(Application.dataPath, "JoyPacSDK/Core/Plugins/Android/JoyPacAndroidManifest.xml"); + + + // Check if user has already created AndroidManifest.xml file in its location. + // If not, use already predefined AdjustAndroidManifest.xml as default one. + + + if (!Directory.Exists(androidPluginsPath)) + { + Directory.CreateDirectory(androidPluginsPath); + } + + if (!File.Exists(appManifestPath)) + { + File.Copy(JoyPacManifestPath, appManifestPath); + AssetDatabase.Refresh(); + } + + + XmlDocument manifestFile = ManifestFile(); + + XmlNode applicationNode = ApplicationNode(manifestFile); + + + if (!TagChack("UMENG_CHANNEL", applicationNode)) + { + XmlElement element_UMENG_CHANNEL = manifestFile.CreateElement("meta-data"); + element_UMENG_CHANNEL.SetAttribute("android_name", "UMENG_CHANNEL"); + element_UMENG_CHANNEL.SetAttribute("android_value", "googleplay"); + applicationNode.AppendChild(element_UMENG_CHANNEL); + Debug.Log("加入【UMENG_CHANNEL】"); + } + + + + TagChack(ManifestApplicationAdmobTag, applicationNode); + SetAdmobAppID(manifestFile, applicationNode); + + TagChack(ManifestApplicationUmengTag, applicationNode); + SetUmengAppKey(manifestFile, applicationNode); + + manifestFile.Save(appManifestPath); + CleanManifestFile(appManifestPath); + JPPackageManager.ShowTips("提示", "android端-" + "写入AndroidManifest.xml文件成功"); + + } + //[MenuItem("JoyPacSDK /chack")] + + //public static void TagChack() + //{ + // Debug.Log(TagChack(ManifestApplicationAdmobTag)); + //} + public static bool TagChack(string str, XmlNode applicationNode) + { + + + foreach (XmlNode node in applicationNode.ChildNodes) + { + if (node.Name == "meta-data") + { + foreach (XmlAttribute attribute in node.Attributes) + { + + if (attribute.Value.Contains(str)) + { + if (str == ManifestApplicationAdmobTag || str == ManifestApplicationUmengTag) + { + applicationNode.RemoveChild(node); + Debug.Log("删除原 " + str); + } + + return true; + } + + + + } + } + } + return false; + + } + public static void CleanManifestFile(String manifestPath) + { + // Due to XML writing issue with XmlElement methods which are unable + // to write "android:[param]" string, we have wrote "android__[param]" string instead. + // Now make the replacement: "android:[param]" -> "android__[param]" + + TextReader manifestReader = new StreamReader(manifestPath); + string manifestContent = manifestReader.ReadToEnd(); + manifestReader.Close(); + + Regex regex = new Regex("android_"); + manifestContent = regex.Replace(manifestContent, "android:"); + + Regex regex1 = new Regex("tools_"); + manifestContent = regex1.Replace(manifestContent, "tools:"); + + TextWriter manifestWriter = new StreamWriter(manifestPath); + manifestWriter.Write(manifestContent); + manifestWriter.Close(); + } + + public static void PropertiesPar() + { + IEnumerable PropertiesFie = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, JPReleaseAreaType.OS, JPEditorComponentType.Properties); + + Properties.Clear(); + foreach (var info in PropertiesFie) + { + if (info.FieldType == typeof(string)) + { + Properties.AddKey(info.Name, (string)info.GetValue(AutomationManager.JoyPacParams)); + + } + } + + + + } + + + [MenuItem("JoyPacSDK/更新Properties文件(Update the Properties file)")] + public static void WriteProperties() + { + + JPPackageManager.ShowProcessBar("Android端-" + "正在写入Properties文件", 0.3f); + PropertiesPar(); + bool issuccess = Properties.CreatAndWriteProperties(); + + AssetDatabase.Refresh(); + JPPackageManager.HideProcessBar(); + if (!issuccess) + JPPackageManager.ShowTips("Error", "android端-" + "写入Properties文件失败,请查看控制台信息 "); + else + JPPackageManager.ShowTips("提示", "android端-" + "写入Properties文件成功"); + + } + + + + public static void WriteProperties(bool istrue) + { + JPPackageManager.ShowProcessBar("Android端-" + "正在写入Properties文件", 0.3f); + PropertiesPar(); + bool issuccess = Properties.CreatAndWriteProperties(); + + AssetDatabase.Refresh(); + JPPackageManager.HideProcessBar(); + if (!issuccess) + JPPackageManager.ShowTips("Error", "android端-" + "写入Properties文件失败,请查看控制台信息 "); + else + JPPackageManager.ShowTips("提示", "android端-" + "写入Properties文件成功"); + GUIUtility.ExitGUI(); + } + + + + +#endif + + [MenuItem("JoyPacSDK /更新json参数文件(Update the JSON parameter file)")] + public static void UpdateStringKey() + { + + StringKeyManger.Instance.ClearStringKeyDic(StringKeyManger.Instance.StringKeyDic); + //平台 + JPReleaseAreaType jPReleaseAreaType = GetJPReleaseAreaType(); + if (JPPackageManager.HasComponent(JPComponenetType.Ga_Adjust)) + { + Ga_AdjustParams(jPReleaseAreaType); + //adjust事件 + if (StringKeyManger.Instance.isHaveAdjustEvent) + AdjustEventParams(jPReleaseAreaType); + } + JoyPacSettingParams(jPReleaseAreaType); + + if (JPPackageManager.HasComponent(JPComponenetType.Umeng)) + UmengParams(jPReleaseAreaType); + + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd) || JPPackageManager.HasComponent(JPComponenetType.JoyPacAd_Android)) + JoyPacParams(jPReleaseAreaType); + StringKeyManger.Instance.SerializeDictionaryToJsonString(StringKeyManger.Instance.StringKeyDic, StringKeyManger.Instance.JsonPath); + AssetDatabase.Refresh(); + + } + #region ga_adjust参数处理 + public static void Ga_AdjustParams(JPReleaseAreaType type) + { + +#if UNITY_IOS + IEnumerable Ga_AdjustFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, type, JPEditorComponentType.Ga_Adjust); +#elif UNITY_ANDROID + IEnumerable Ga_AdjustFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, type, JPEditorComponentType.Ga_Adjust); +#elif UNITY_EDITOR + IEnumerable Ga_AdjustFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Editor, type, JPEditorComponentType.Ga_Adjust); ; +#endif + + foreach (var info in Ga_AdjustFieldInfo) + { + + if (info.FieldType == typeof(string)) + { + + +#if UNITY_IOS + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_ANDROID + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_EDITOR + string jsonKey = ""; +#endif + StringKeyManger.Instance.AddStringKeyDic(jsonKey, (string)info.GetValue(AutomationManager.JoyPacParams), StringKeyManger.Instance.StringKeyDic); + + } + if (info.FieldType == typeof(bool)) + StringKeyManger.Instance.isHaveAdjustEvent = (bool)info.GetValue(AutomationManager.JoyPacParams); + + + } + } + #endregion + + #region adjustEvent参数处理 + public static void AdjustEventParams(JPReleaseAreaType type) + { + +#if UNITY_IOS + IEnumerable AdjustEventFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, type, JPEditorComponentType.AdjustEvent); +#elif UNITY_ANDROID + IEnumerable AdjustEventFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, type, JPEditorComponentType.AdjustEvent); +#elif UNITY_EDITOR + IEnumerable AdjustEventFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Editor, type, JPEditorComponentType.AdjustEvent); ; + //ga_adjust参数 +#endif + + foreach (var info in AdjustEventFieldInfo) + { + if (info.FieldType == typeof(string)) + { + +#if UNITY_IOS + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_ANDROID + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_EDITOR + string jsonKey = ""; + +#endif + StringKeyManger.Instance.AddStringKeyDic(jsonKey, (string)info.GetValue(AutomationManager.JoyPacParams), StringKeyManger.Instance.StringKeyDic); + + } + + } + } + #endregion + + #region 友盟参数处理 + public static void UmengParams(JPReleaseAreaType type) + { + +#if UNITY_IOS + IEnumerable UmengFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, type, JPEditorComponentType.Umeng); + +#elif UNITY_ANDROID + IEnumerable UmengFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, type, JPEditorComponentType.Umeng); +#elif UNITY_EDITOR + IEnumerable UmengFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Editor, type, JPEditorComponentType.Umeng); ; + +#endif + foreach (var info in UmengFieldInfo) + { + if (info.FieldType == typeof(string)) + { + + +#if UNITY_IOS + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_ANDROID + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_EDITOR + string jsonKey = ""; +#endif + StringKeyManger.Instance.AddStringKeyDic(jsonKey, (string)info.GetValue(AutomationManager.JoyPacParams), StringKeyManger.Instance.StringKeyDic); + + } + + } + } + #endregion + + #region AppID参数处理 + + public static void JoyPacSettingParams(JPReleaseAreaType type) + { + +#if UNITY_IOS + IEnumerable JoyPacSettingFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, type, JPEditorComponentType.JoyPacSetting); + +#elif UNITY_ANDROID + IEnumerable JoyPacSettingFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, type, JPEditorComponentType.JoyPacSetting); +#elif UNITY_EDITOR + IEnumerable JoyPacSettingFieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Editor, type, JPEditorComponentType.JoyPacSetting); ; + +#endif + foreach (var info in JoyPacSettingFieldInfo) + { + if (info.FieldType == typeof(string)) + { + +#if UNITY_IOS + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_ANDROID + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_EDITOR + string jsonKey = ""; + +#endif + StringKeyManger.Instance.AddStringKeyDic(jsonKey, (string)info.GetValue(AutomationManager.JoyPacParams), StringKeyManger.Instance.StringKeyDic); + + + } + } + } + #endregion + + #region JoyPac AdParams参数处理 + public static void JoyPacParams(JPReleaseAreaType type) + { + +#if UNITY_IOS + IEnumerable JoyPacieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.iOS, type, JPEditorComponentType.AdParams); + +#elif UNITY_ANDROID + IEnumerable JoyPacieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Android, type, JPEditorComponentType.AdParams); +#elif UNITY_EDITOR + IEnumerable JoyPacieldInfo = GetInitParamsFieldInfoByComponentType(JPEditorPlatformType.Editor, type, JPEditorComponentType.AdParams); ; + +#endif + foreach (var info in JoyPacieldInfo) + { + if (info.FieldType == typeof(string)) + { + + +#if UNITY_IOS + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_ANDROID + string jsonKey = info.Name.Remove(0, RemoveCount); +#elif UNITY_EDITOR + string jsonKey = ""; +#endif + + StringKeyManger.Instance.AddStringKeyDic(jsonKey, (string)info.GetValue(AutomationManager.JoyPacParams), StringKeyManger.Instance.StringKeyDic); + + } + + } + } + + #endregion + + #region 测试阶段JoyPacAdNet + public static JPAdNType[] JoyPacAdNet(JPReleaseAreaType releaseAreaType) + { + List jPAdNTypes = new List(); + if (JPPackageManager.HasComponent(JPComponenetType.JoyPacAd)) + { + + + switch (releaseAreaType) + { + case JPReleaseAreaType.CN: + jPAdNTypes.Add(JPAdNType.pangle_China); + break; + case JPReleaseAreaType.OS: + jPAdNTypes.Add(JPAdNType.pangle_nonChina); + break; + } + + + } + return jPAdNTypes.ToArray(); + } + #endregion + + + + public static void logtest() + { + //Debug.Log(DynamicStringsKey.Instance.JOYPAC_SDK_APPID); + + //Debug.Log(DynamicStringsKey.Instance.ADJUST_APP_TOKEN); + //Debug.Log(DynamicStringsKey.Instance.GA_gameKey); + //Debug.Log(DynamicStringsKey.Instance.GA_secretKey); + + + + //Debug.Log(DynamicStringsKey.Instance.NATIVE_SHOW_TOKEN); + //Debug.Log(DynamicStringsKey.Instance.DEVICEINFO_IPAD_TOKEN); + + //Debug.Log(DynamicStringsKey.Instance.DEVICEINFO_IPHONE_TOKEN); + //Debug.Log(DynamicStringsKey.Instance.PLAY_10_TOKEN); + + //Debug.Log(DynamicStringsKey.Instance.INTERSITIAL_SHOW_COUNT_TOKEN); + + //Debug.Log(DynamicStringsKey.Instance.SECOND_LAUNCH_DAY_TOKEN); + + //Debug.Log(DynamicStringsKey.Instance.VIDEO_SHOW_COUNT_TOKEN); + //Debug.Log(DynamicStringsKey.Instance.VIDEO_AND_INTERITIAL_COUNT_TOKEN); + + //Debug.Log(DynamicStringsKey.Instance.FIRST_RATE_TOKEN); + + + + //Debug.Log(DynamicStringsKey.Instance.ADJUST_EVENT_RV24); + //Debug.Log(DynamicStringsKey.Instance.ADJUST_EVENT_RVIV24); + } + + +} +#endif diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParamsManager.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParamsManager.cs.meta new file mode 100644 index 00000000..55b5b011 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Params/JoyPacParamsManager.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: e6a4526bb399460dae0bb721f2438c0b +timeCreated: 1615378759 \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Properties.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties.meta new file mode 100644 index 00000000..2ecab694 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b37bf12472f93489899e1f8e118c8e96 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/Properties.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/Properties.cs new file mode 100644 index 00000000..a1e41064 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/Properties.cs @@ -0,0 +1,193 @@ +#if UNITY_EDITOR +using System.Collections.Generic; +using System.IO; +using UnityEngine; + +/// +/// Key_是有固定value值的key,不需要开发者填 +/// +public static class Properties +{ + public static string strRew = Application.dataPath + "/Plugins/Android/res/raw"; + public static string strFilePath = strRew + "/joypac_games_config.properties"; + + #region Key + public const string package_name = "package_name"; + + public const string gamename = "gamename"; + + public const string app_setting_name = "app_setting_name"; + + public const string app_setting_appid = "app_setting_appid"; + + public const string app_settting_def_key = "app_settting_def_key"; + + public const string splash_orientation_key = "splash_orientation_key"; + + public const string umeng_appkey = "umeng_appkey"; + + public const string joypac_app_name = "joypac_app_name"; + + #region 无固定value值,但是不需要开发者填的key + + + + + public const string D_unit_exit_setting_name = "unit_exit_setting_name"; + + public const string D_unit_splash_setting_name = "unit_splash_setting_name"; + #endregion + + #region 有固定value值的key + + + public const string Key_base_game_main_activity_class_name = "base_game_main_activity_class_name"; + + public const string Key_libs_analytics = "libs_analytics"; + + + public const string Key_umeng_channel = "umeng_channel"; + + public const string Key_core_sdk = "core_sdk"; + + public const string Key_splash_type_key = "splash_type_key"; + + public const string Key_useAd = "useAd"; + + public const string Key_useSplitDex = "useSplitDex"; + + public const string Key_useGradle611 = "useGradle611"; + + public const string Key_splash_img_key = "splash_img_key"; + #endregion + + + + #endregion + + #region 固定value值value + public const string Value_UnityPlayerActivity = "com.joypac.JoypacUnityPlayerActivity"; + + public const string Value_umeng_channel = "googleplay"; + + public const string Value_splash_type_key = "splash_joypac"; + + public const bool Value_useAd = true; + + public const string Value_splash_img_key = "splash_img_international"; + + + #endregion + + #region 临时存储value + + #endregion + + public static Dictionary PropertiesDic = new Dictionary(); + + + public static Dictionary Const_PropertiesDic = new Dictionary + { + + { Key_base_game_main_activity_class_name, Value_UnityPlayerActivity }, + { Key_umeng_channel, Value_umeng_channel }, + { Key_splash_type_key, Value_splash_type_key }, + + { Key_splash_img_key, Value_splash_img_key }, + { Key_useAd, Value_useAd }, }; + + public static void AddKey(string key, string value) + { + PropertiesDic.Add(key, value); + } + public static void Clear() + { + PropertiesDic.Clear(); + } + + + public static void CreatFile() + { + + if (!File.Exists(strRew)) // 判断是否已有相同文件 + { + Directory.CreateDirectory(strRew); + } + + + } + + + public static bool CreatAndWriteProperties() + { + try + { + bool WritePropertiesSuccess = true; + CreatFile(); + if (File.Exists(strFilePath)) + File.Delete(strFilePath); + + FileStream fs1 = new FileStream(strFilePath, FileMode.Create, FileAccess.ReadWrite); + fs1.Close(); + + PropertyOper propertyOper = new PropertyOper(Properties.strFilePath); + + if (string.IsNullOrEmpty(DynamicStringsKey.Instance.JOYPAC_SDK_APPID)) + { + WritePropertiesSuccess = false; + Debug.LogError("[JoyPacSDK]:请填写 JOYPAC_SDK_APPID 的值"); + } + propertyOper.Add(app_setting_appid, DynamicStringsKey.Instance.JOYPAC_SDK_APPID); + foreach (var item in PropertiesDic) + { + if (string.IsNullOrEmpty(item.Value.ToString())) + { + WritePropertiesSuccess = false; + Debug.LogError("[JoyPacSDK]:请填写 " + item.Key + " 的值"); + } + propertyOper.Add(item.Key, item.Value.ToString()); + + } + foreach (var item in Const_PropertiesDic) + { + propertyOper.Add(item.Key, item.Value.ToString()); + } + + + if (string.IsNullOrEmpty(DynamicStringsKey.Instance.JoypacAppName)) + { + WritePropertiesSuccess = false; + Debug.LogError("[JoyPacSDK]:请填写 JoypacAppName 的值"); + } + propertyOper.Add(D_unit_splash_setting_name, DynamicStringsKey.Instance.JoypacAppName + "SP"); + + + + if (string.IsNullOrEmpty(DynamicStringsKey.Instance.UMENG_APPKEY)) + { + WritePropertiesSuccess = false; + Debug.LogError("[JoyPacSDK]:请填写 UMENG_APPKEY 的值"); + } + propertyOper.Add(umeng_appkey, DynamicStringsKey.Instance.UMENG_APPKEY); + + propertyOper.Save(); + return WritePropertiesSuccess; + } + catch (System.Exception ex) + { + Debug.LogError(ex); + } + return false; + + } + + + public static void chackProperties() + { + if (!File.Exists(strFilePath)) + { + Debug.LogError(strFilePath + " 不存在,请重新生成"); + } + } +} +#endif diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/Properties.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/Properties.cs.meta new file mode 100644 index 00000000..f629dea4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/Properties.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 51b8c49efbc1e493bbfdd5606b1b4ba2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/PropertyOper.cs b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/PropertyOper.cs new file mode 100644 index 00000000..4dcbf9ac --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/PropertyOper.cs @@ -0,0 +1,178 @@ +using System.Collections; +using System.Collections.Generic; +using System.IO; +using UnityEngine; +using UnityEditor; + +public class PropertyOper : System.Collections.Hashtable +{ + private string fileName = ""; + private ArrayList list = new ArrayList(); + private string v; + + public PropertyOper(string fileName) + { + this.fileName = fileName; + this.Load(fileName); + } + public ArrayList List + { + get { return list; } + set { list = value; } + } + + /// + /// 重写父类的方法 + /// + /// 键 + /// 值 + public override void Add(object key, object value) + { + + if (!list.Contains(key)) + { + base.Add(key, value); + list.Add(key); + } + + else + this.Update(key, value); + + + } + + public void Update(object key, object value) + { + base.Remove(key); + list.Remove(key); + this.Add(key, value); + + } + public override ICollection Keys + { + get + { + return list; + } + } + /// + /// 加载文件 + /// + /// 文件路径 + public void Load(string filePath) + { + + int limit; + int keyLen; + int valueStart; + char c; + string bufLine = string.Empty; + bool hasSep; + bool precedingBackslash; + using (StreamReader sr = new StreamReader(filePath)) + { + while (sr.Peek() >= 0) + { + bufLine = sr.ReadLine(); + limit = bufLine.Length; + keyLen = 0; + valueStart = limit; + hasSep = false; + precedingBackslash = false; + if (bufLine.StartsWith("#")) + keyLen = bufLine.Length; + while (keyLen < limit) + { + c = bufLine[keyLen]; + if ((c == '=' || c == ':') & !precedingBackslash) + { + valueStart = keyLen + 1; + hasSep = true; + break; + } + else if ((c == ' ' || c == '\t' || c == '\f') & !precedingBackslash) + { + valueStart = keyLen + 1; + break; + } + if (c == '\\') + { + precedingBackslash = !precedingBackslash; + } + else + { + precedingBackslash = false; + } + keyLen++; + } + while (valueStart < limit) + { + c = bufLine[valueStart]; + if (c != ' ' && c != '\t' && c != '\f') + { + if (!hasSep && (c == '=' || c == ':')) + { + hasSep = true; + } + else + { + break; + } + } + valueStart++; + } + string key = bufLine.Substring(0, keyLen); + string values = bufLine.Substring(valueStart, limit - valueStart); + if (key == "") + key += "#"; + while (key.StartsWith("#") & this.Contains(key)) + { + key += "#"; + } + this.Add(key, values); + } + } + } + /// + /// 保存文件 + /// + /// 要保存的文件的路径 + public void Save() + { + string filePath = this.fileName; + if (File.Exists(filePath)) + { + File.Delete(filePath); + } + FileStream fileStream = File.Create(filePath); + StreamWriter sw = new StreamWriter(fileStream); + foreach (object item in list) + { + string key = (string)item; + string val = (string)this[key]; + if (key.StartsWith("#")) + { + if (val == "") + { + sw.WriteLine(key); + } + else + { + sw.WriteLine(val); + } + } + else + { + sw.WriteLine(key + "=" + val); + } + } + sw.Close(); + fileStream.Close(); + } + + + +} + + + diff --git a/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/PropertyOper.cs.meta b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/PropertyOper.cs.meta new file mode 100644 index 00000000..2fcb7fa9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Automation/Properties/PropertyOper.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7818369f8e54d4872a142ec12bedbb92 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/JPPackageManager.cs b/popcorn/Assets/JoyPacSDK/Core/JPPackageManager.cs new file mode 100644 index 00000000..20ab23d6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/JPPackageManager.cs @@ -0,0 +1,2244 @@ +#if UNITY_EDITOR +using System; +using System.Collections.Generic; +using System.IO; +using System.IO.Compression; +using System.Linq; +using System.Text; +using System.Xml; +using UnityEditor; +using UnityEngine; + + +public enum JPComponenetType +{ + Core,// 核心模块 + Ga_Adjust,// 账号模块 + Push,// 支付模块. + JoyPacAd,//广告模块 + Umeng,//友盟 + JoyPacAd_Android//安卓广告 +} + +// AdNet 各个类型 +public enum JPAdNType +{ + core,//核心框架 必填 + admob,// 谷歌广告 + gdt,// 广点通 + ironsource,// ironsource广告 + unityads,// Unity-Ad + mintegral, // MIntegral + vungle,// vungle + adcolony, + chartboost, + fyber, + KlevinSDK, + kuaishou, + maio, + applovin, + facebook, + pangle_China,//国内 + pangle_nonChina//海外 + +} +[InitializeOnLoad] +public static class JPPackageManager +{ + // SDK根目录 + private const string SdkRootDir = "Assets/JoyPacSDK"; + + private const string JoyPacAD_SDK_Android_OS = "JoyPacAD_SDK_Android_OS"; + private const string Android_topon_version = "5.7.81"; + + // 导出最终包的unity package前缀. + private const string SdkNamePreFix = "JoyPac_SDK"; + + // 自动化插件相对路径. + public static readonly string AutomationPluginsRelativePath = Path.Combine(SdkRootDir, "Core/Automation"); + + //// JoyPacSDK 菜单组件 + //public const string MENU_JOYPAC_SDK_COMPONENT = "JoyPacSDK/组件配置(Configure Component)/"; + + // sdk目录的绝对路径. + public static readonly string SdkAbsDirectory = Path.Combine(Environment.CurrentDirectory, SdkRootDir); + + // iOSAdn所在目录. + private static readonly string iOS_Adn_Dir = + Path.Combine(GetComponentDir(JPComponenetType.JoyPacAd), "JoyPacAd/Plugins/iOS/Third"); + + + // iOSAdn所在目录. + private static readonly string __MACOSX = Path.Combine(SdkRootDir, "JoyPacAd/__MACOSX"); + // public static readonly string targetPath = Application.dataPath + "/" + JPService.info_target_path + "/Plugins/iOS/" + JPService.info_plist_name; + // iosADN隐藏目录. + private static readonly string iOS_Adn_Hidden_Dir = + Path.Combine(GetComponentHiddenDir(JPComponenetType.JoyPacAd), "JoyPacAd/Plugins/iOS/Third"); + + /// + /// 检查当前是否有某个组件. + /// + /// 组件. + /// 是否有某个组件. + public static bool HasComponent(JPComponenetType componentType) + { + return Directory.Exists(Path.Combine(SdkAbsDirectory, componentType.ToString())); + } + + static JPPackageManager() + { + AssetDatabase.importPackageCompleted += OnImportFinishHandle; + } + + /// + /// 导入包完成后对sdk文件的处理. + /// + /// 导入的包名. + private static void OnImportFinishHandle(string packageName) + { + + if (packageName == JoyPacAD_SDK_Android_OS + "_" + Android_topon_version) + AllProcessing(); + + return; + + if (!packageName.Contains(SdkNamePreFix)) + { + // ignore 非sdk包引入,不做处理 + return; + } + + // 展示进度条 + ShowProcessBar("SDK处理中,请稍等片刻...", 0f); + + try + { + + // 处理广告组件 + var AdImport = HandleComponent(JPComponenetType.JoyPacAd); + + // 关闭进度条 + HideProcessBar(); + + // 提示sdk导入成功. + if (AdImport) + { + // 刷新Assets + AssetDatabase.Refresh(); + ShowTips("恭喜", "JoyPacSDK导入完成,可以使用SDK功能啦~"); + } + else + { + ShowTips("提示", "JoyPacSDK导入失败,请重新导入~"); + } + } + catch (Exception e) + { + PrintError(e.ToString()); + // 隐藏进度条. + HideProcessBar(); + ShowTips("提示", "JoyPacSDK导入失败,请检查项目文件~"); + } + } + + + + [MenuItem("JoyPacSDK/JoyPacSDKAndroid设置失败请点击此处【JoyPacSDKAndroid setup failed please click here】")] + public static void AllProcessing() + { + AndroidManifestXml(); + NetworkSecurity(); + AndroidGradle(); + if (chackPath()) + { + // 刷新Assets + AssetDatabase.Refresh(); + ShowTips("恭喜【Congratulations】", "JoyPacSDKAndroid设置完成,可以使用SDK功能啦~【JoyPacSDKAndroid is ready to use the SDK~】"); + } + else + { + ShowTips("提示【warning】", "JoyPacSDKAndroid设置失败,请重新手动设置【Failed to set JoyPacSDKAndroid. Please manually set it again】"); + } + + string str = PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android); + Debug.Log("old " + str); + str = str.Replace("ANDROID_GP", null); + + PlayerSettings.SetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android, + "ANDROID_GP" + ";" + str); + Debug.Log("new " + PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Android)); + + + Debug.Log("当前平台为海外"); + } + + + + + public static string appManifestPath = Path.Combine(Application.dataPath, "Plugins/Android/AndroidManifest.xml"); + + public static string appBaseProjectTemplate = Path.Combine(Application.dataPath, "Plugins/Android/baseProjectTemplate.gradle"); + public static string appLauncherTemplate = Path.Combine(Application.dataPath, "Plugins/Android/launcherTemplate.gradle"); + public static string appMainTemplate = Path.Combine(Application.dataPath, "Plugins/Android/mainTemplate.gradle"); + public static string appgradleTemplate = Path.Combine(Application.dataPath, "Plugins/Android/gradleTemplate.properties"); + + public static string xmlPath = Path.Combine(Application.dataPath, "Plugins/Android/res/xml"); + public static string Network_security_config = Path.Combine(xmlPath, "network_security_config.xml"); + + public static string[] path = new[] + { + appManifestPath, + appBaseProjectTemplate, + appLauncherTemplate, + appMainTemplate, + appgradleTemplate, + Network_security_config, + + }; + + + private static void NetworkSecurity() + { + + string JoyPacNetwork_security_config = Path.Combine(Path.Combine(Application.dataPath, "JoyPacSDK/Core/Plugins/Android/network_security_config.xml")); + + if (!Directory.Exists(xmlPath)) + { + Directory.CreateDirectory(xmlPath); + + } + if (!File.Exists(Network_security_config)) + { + File.Copy(JoyPacNetwork_security_config, Network_security_config); + UnityEngine.Debug.Log("[JoyPacSDK]: User defined network_security_config.xml file not found in Plugins/Android/res/xml folder."); + AssetDatabase.Refresh(); + + } + + } + private static void AndroidManifestXml() + { + string androidPluginsPath = Path.Combine(Application.dataPath, "Plugins/Android"); + string JoyPacManifestPath = Path.Combine(Application.dataPath, "JoyPacSDK/Core/Plugins/Android/JoyPacAndroidManifest.xml"); + + + if (File.Exists(appManifestPath)) + { + File.Delete(appManifestPath); + UnityEngine.Debug.Log("[JoyPacSDK]: Delete the original AndroidManifest.xml."); + } + + if (!Directory.Exists(androidPluginsPath)) + { + Directory.CreateDirectory(androidPluginsPath); + UnityEngine.Debug.Log("[JoyPacSDK]: User defined AndroidManifest.xml file not found in Plugins/Android folder."); + } + + File.Copy(JoyPacManifestPath, appManifestPath); + + AssetDatabase.Refresh(); + + UnityEngine.Debug.Log("[JoyPacSDK]: Creating default app's AndroidManifest.xml from JoyPacAndroidManifest.xml file."); + + } + + private static void AndroidGradle() + { + string androidPluginsPath = Path.Combine(Application.dataPath, "Plugins/Android"); + + string JoyPacBaseProjectTemplate = Path.Combine(Path.Combine(Application.dataPath, "JoyPacSDK/Core/Plugins/Android/baseProjectTemplate.gradle")); + + string JoyPacLauncherTemplate = Path.Combine(Path.Combine(Application.dataPath, "JoyPacSDK/Core/Plugins/Android/launcherTemplate.gradle")); + + + string JoyPacMainTemplate = Path.Combine(Path.Combine(Application.dataPath, "JoyPacSDK/Core/Plugins/Android/mainTemplate.gradle")); + + + + string JoyPacgradleTemplate = Path.Combine(Path.Combine(Application.dataPath, "JoyPacSDK/Core/Plugins/Android/gradleTemplate.properties")); + + // Check if user has already created AndroidManifest.xml file in its location. + // If not, use already predefined AdjustAndroidManifest.xml as default one. + + + if (!Directory.Exists(androidPluginsPath)) + { + Directory.CreateDirectory(androidPluginsPath); + UnityEngine.Debug.Log("[JoyPacSDK]: User defined Gradle file not found in Plugins/Android folder."); + } + if (File.Exists(appBaseProjectTemplate)) + { + File.Delete(appBaseProjectTemplate); + UnityEngine.Debug.Log("[JoyPacSDK]: Delete the original appBaseProjectTemplate.gradle"); + } + if (File.Exists(appLauncherTemplate)) + { + File.Delete(appLauncherTemplate); + UnityEngine.Debug.Log("[JoyPacSDK]: Delete the original launcherTemplate.gradle"); + } + if (File.Exists(appMainTemplate)) + { + File.Delete(appMainTemplate); + UnityEngine.Debug.Log("[JoyPacSDK]: Delete the original mainTemplate.gradle"); + } + if (File.Exists(appgradleTemplate)) + { + File.Delete(appgradleTemplate); + UnityEngine.Debug.Log("[JoyPacSDK]: Delete the original mainTemplate.gradle"); + } + + File.Copy(JoyPacBaseProjectTemplate, appBaseProjectTemplate); + File.Copy(JoyPacLauncherTemplate, appLauncherTemplate); + File.Copy(JoyPacMainTemplate, appMainTemplate); + File.Copy(JoyPacgradleTemplate, appgradleTemplate); + AssetDatabase.Refresh(); + + + UnityEngine.Debug.Log("[JoyPacSDK]: Creating default app's Gradle."); + } + + public static bool chackPath() + { + + foreach (var apppath in path) + { + if (!File.Exists(apppath)) + return false; + } + return true; + } + + + // [MenuItem("JoyPacSDK/处理广告组件JoyPacAd.zip(Handles the advertising component JoyPacAd.zip)")] + public static void OnImportFinishHandle() + { // 展示进度条 + ShowProcessBar("SDK处理中,请稍等片刻...", 0f); + + try + { + // 处理广告组件 + var AdImport = HandleComponent(JPComponenetType.JoyPacAd); + + + + // 关闭进度条 + HideProcessBar(); + + + // 提示sdk导入成功. + if (AdImport) + { + // 刷新Assets + + AssetDatabase.Refresh(); + ShowTips("恭喜", "JoyPacSDK导入完成,可以使用SDK功能啦~"); + } + else + { + ShowTips("提示", "JoyPacSDK导入失败,请重新导入~"); + } + } + catch (Exception e) + { + PrintError(e.ToString()); + // 隐藏进度条. + HideProcessBar(); + ShowTips("提示", "JoyPacSDK导入失败,请检查项目文件~"); + } + + } + + /// + /// 处理广告模块组件. + /// + private static bool HandleComponent(JPComponenetType componentType) + { + // zip包路径. + var componentZipPath = GetComponentZipPath(componentType); + // 组件所在目录. + var componentDirPath = GetComponentDir(componentType); + // 组件隐藏目录. + var componentHiddenDir = GetComponentHiddenDir(componentType); + if (!File.Exists(componentZipPath)) + { + Debug.LogError(componentZipPath + "不存在"); + return false; + } + + // 删除旧版本中的目录. + DeleteFolder(componentDirPath); + // 删除旧版本中的隐藏目录. + DeleteFolder(componentHiddenDir); + + // 解压到项目目录 + ZipFile.ExtractToDirectory(componentZipPath, componentDirPath); + // 同时也解压到当前组件隐藏目录 + ZipFile.ExtractToDirectory(componentZipPath, componentHiddenDir); + + DeleteFolder(__MACOSX); + removeOtherAd(); + // 修改iOS平台类型. + Modify_iOSFolderPlatformType(componentDirPath); + + + // 删除zip包. + File.Delete(componentZipPath); + + + return true; + } + + private static void removeOtherAd() + { + JPAdNType[] adNTypes = new JPAdNType[] + { + JPAdNType.pangle_China, + }; + + foreach (var adNType in adNTypes) + { + + RemoveFolderByMatchingTag(iOS_Adn_Dir, adNType.ToString()); + } + + } + + /// + /// 备份组件,此方法sdk内部使用. + /// + public static void BackupComponent() + { + try + { + + ShowProcessBar("Ad 组件备份中 请稍后..", 0.8f); + BackupComponent(JPComponenetType.JoyPacAd); + + ShowTips("恭喜", "组件备份成功"); + } + catch (Exception e) + { + PrintError(e.ToString()); + HideProcessBar(); + } + } + + // 备份组件 + private static void BackupComponent(JPComponenetType componenetType) + { + // 组件隐藏目录. + var componentHiddenDir = GetComponentHiddenDir(componenetType); + // 组件所在目录. + var componentDirPath = GetComponentDir(componenetType); + // 删除旧版本中的隐藏目录. + DeleteFolder(componentHiddenDir); + // 同时也解压到当前组件隐藏目录 + CopyFolder(componentDirPath, componentHiddenDir); + } + + #region SDK相关路径 + + /// + /// 获取sdk所在目录. + /// + /// + private static string GetSdkDir() + { + return Path.Combine(Environment.CurrentDirectory, SdkRootDir); + } + + /// + /// 获取组件路径. + /// + /// 组件类型. + /// 当前组件所在路径. + public static string GetComponentDir(JPComponenetType componenetType) + { + return Path.Combine(GetSdkDir(), componenetType.ToString()); + } + + + /// + /// 获取组件zip包所在路径. + /// + /// + /// 当前zip包所在路径. + private static string GetComponentZipPath(JPComponenetType componenetType) + { + + return GetComponentDir(componenetType) + ".zip"; + } + + /// + /// 获取组件隐藏目录. + /// + /// + /// + private static string GetComponentHiddenDir(JPComponenetType componenetType) + { + return Path.Combine(GetSdkDir(), componenetType.ToString()) + "_Backup~"; + } + + #endregion + + + + + + /// + /// 添加lib文件到工程目录. + /// + /// 文件路径. + /// 文件目标路径. + /// 文件的tag,前缀. + private static void AddLibFileToProject(string filePath, string fileTargetPath, string tag) + { + var srcDirInfo = new DirectoryInfo(filePath); + if (srcDirInfo.Exists) + { + var fileSystemInfos = srcDirInfo.GetFileSystemInfos(); + foreach (var fileSystemInfo in fileSystemInfos) + { + // 找到对应的文件. + if (fileSystemInfo.Exists && fileSystemInfo.Name.ToLower().Contains(tag.ToLower())) + { + var targetFilePath = Path.Combine(fileTargetPath, fileSystemInfo.Name); + if (File.Exists(targetFilePath)) + { + File.Delete(targetFilePath); + } + + File.Copy(fileSystemInfo.FullName, targetFilePath); + } + } + } + else + { + Debug.LogError("目录不存在."); + } + + AssetDatabase.Refresh(); + } + + /// + /// 移除lib文件. + /// + /// 文件路径. + /// 文件tag,文件名前缀. + private static void RemoveLibFile(string fileDir, string tag) + { + var dirInfo = new DirectoryInfo(fileDir); + if (dirInfo.Exists) + { + var fileSystemInfos = dirInfo.GetFileSystemInfos(); + foreach (var fileSystemInfo in fileSystemInfos) + { + // 找到对应adn,并且移除 + if (fileSystemInfo.Exists && fileSystemInfo.Name.ToLower().Contains(tag.ToLower())) + { + fileSystemInfo.Delete(); + } + } + } + else + { + Debug.LogError("目录不存在."); + } + + AssetDatabase.Refresh(); + } + + /// + /// 添加文件夹到项目中,通过tag匹配. + /// + /// 原文件夹所在位置. + /// 文件夹所在目标位置. + /// 文件夹标记信息. + private static void AddFolderToProjectByMatchingTag(string folderLocated, string targetLocated, string tag) + { + //var srcDirInfo = new DirectoryInfo(folderLocated); + //if (srcDirInfo.Exists) + //{ + // var fileSystemInfos = srcDirInfo.GetFileSystemInfos(); + // foreach (var fileSystemInfo in fileSystemInfos) + // { + // // 找到对应的文件. + // if (fileSystemInfo.Exists + // && fileSystemInfo.Name.ToLower().Contains(tag.ToLower()) + // && fileSystemInfo is DirectoryInfo) + // { + // CopyFolder(fileSystemInfo.FullName, Path.Combine(targetLocated, fileSystemInfo.Name)); + // } + // } + //} + //else + //{ + // Debug.LogError("目录不存在."); + //} + + //AssetDatabase.Refresh(); + } + + /// + /// 通过匹配tag,删除目标目录中的文件夹. + /// + /// + /// + private static void RemoveFolderByMatchingTag(string folderLocated, string tag) + { + //// 文件夹所在目录 + //var dirInfo = new DirectoryInfo(folderLocated); + //if (dirInfo.Exists) + //{ + // var fileSystemInfos = dirInfo.GetFileSystemInfos(); + // foreach (var fileSystemInfo in fileSystemInfos) + // { + // // 检查当前是否为文件夹. + // if (fileSystemInfo.Exists && fileSystemInfo is DirectoryInfo dir) + // { + // if (dir.Name.ToLower().Contains(tag.ToLower())) + // { + // // 递归删除目录 + // dir.Delete(true); + // } + // } + // } + //} + //else + //{ + // Debug.LogError("目录不存在."); + //} + + //AssetDatabase.Refresh(); + } + + + /// + /// iOS端Adn处理. + /// + /// adn类型. + /// 是否勾选adn. + public static void iOS_Adn_Handle(JPAdNType adNType, bool open) + { + ShowProcessBar("iOS端-" + adNType + "正在切换,请稍后", 0.3f); + //try + //{ + // if (open) + // { + // AddFolderToProjectByMatchingTag(iOS_Adn_Hidden_Dir, iOS_Adn_Dir, adNType.ToString()); + // Modify_iOSFolderPlatformType(Path.Combine(iOS_Adn_Dir, adNType.ToString())); + // Debug.Log(Path.Combine(iOS_Adn_Dir, adNType.ToString())); + // } + // else + // { + + + // RemoveFolderByMatchingTag(iOS_Adn_Dir, adNType.ToString()); + // } + //} + //catch (Exception e) + //{ + // PrintError(e.ToString()); + // HideProcessBar(); + //} + + AssetDatabase.Refresh(); + HideProcessBar(); + + ShowTips("提示", "iOS端-" + adNType + (open ? "--引入" : "--移除") + "成功"); + GUIUtility.ExitGUI(); + } + + /// + /// iOS端Adn处理. + /// + /// adn类型. + /// 是否勾选adn. + public static void iOS_Adn_Release_Handle(bool open, JPReleaseAreaType releaseAreaType) + { + + //JPAdNType[] adNTypes = JoyPacParamsManager.JoyPacAdNet(releaseAreaType); + + //ShowProcessBar("iOS端-" + "正在切换" + releaseAreaType.ToString() + " 请稍后", 0.3f); + //try + //{ + + // foreach (var adNType in adNTypes) + // { + + // if (open) + // { + // AddFolderToProjectByMatchingTag(iOS_Adn_Hidden_Dir, iOS_Adn_Dir, adNType.ToString()); + // Modify_iOSFolderPlatformType(Path.Combine(iOS_Adn_Dir, adNType.ToString())); + // } + // else + // { + // RemoveFolderByMatchingTag(iOS_Adn_Dir, adNType.ToString()); + // } + // } + + + //} + //catch (Exception e) + //{ + // PrintError(e.ToString()); + // HideProcessBar(); + //} + + + //AssetDatabase.Refresh(); + //HideProcessBar(); + + //string str = string.Join("、", adNTypes); + + //if (open) + // ShowTips("提示", "iOS端-" + str + "已重新加入 \n " + "\n" + jPReleasePeriod.ToString() + "切换成功"); + //else + // ShowTips("提示", "iOS端-" + str + "已移除 \n " + "\n" + jPReleasePeriod.ToString() + "切换成功"); + + + GUIUtility.ExitGUI(); + } + + + /// + /// iOS端切换发布地区处理 + /// + + + public static void iOS_Adn_Info(JPReleaseAreaType adinfo) + { + ShowProcessBar("iOS端-" + adinfo + "正在切换,请稍后", 0.3f); + + JPReleaseAreaType releaseAreaType = JPReleaseAreaType.Editor; + + switch (adinfo) + { + case JPReleaseAreaType.CN: + releaseAreaType = JPReleaseAreaType.OS; + break; + case JPReleaseAreaType.OS: + releaseAreaType = JPReleaseAreaType.CN; + break; + + } + + JPAdNType[] adNTypeRemove = JoyPacParamsManager.JoyPacAdNet(releaseAreaType); + + JPAdNType[] adNTypeAdd = JoyPacParamsManager.JoyPacAdNet(adinfo); + + try + { + + foreach (var adNType in adNTypeRemove) + { + + RemoveFolderByMatchingTag(iOS_Adn_Dir, adNType.ToString()); + } + + foreach (var adNType in adNTypeAdd) + { + + AddFolderToProjectByMatchingTag(iOS_Adn_Hidden_Dir, iOS_Adn_Dir, adNType.ToString()); + + Modify_iOSFolderPlatformType(Path.Combine(iOS_Adn_Dir, adNType.ToString())); + + } + + } + catch (Exception e) + { + + PrintError(e.ToString()); + HideProcessBar(); + + } + + AssetDatabase.Refresh(); + HideProcessBar(); + + var str = "发行地区: " + adinfo.ToString(); + //var strRemove = "Remove " + releaseAreaType.ToString() + "AdNet : " + string.Join("、", adNTypeRemove); + //var strAdd = "Add " + adinfo.ToString() + "AdNet :" + string.Join("、", adNTypeAdd); + + ShowTips("提示", "iOS端-" + str + "切换成功" + "\n\n 请导入对应广告"); + GUIUtility.ExitGUI(); + } + + + + // [MenuItem("JoyPacSDK/引入JoypacService-info文件(import JoypacService-info)")] + public static void iOS_Adn_Info() + { + //{ + // JPReleaseAreaType adinfo = JoyPacParamsManager.GetJPReleaseAreaType(); + // string sourcePath = Application.dataPath + "/" + JPService.info_target_path + "/info/" + adinfo + "/" + JPService.info_plist_name; + // try + // { + // JoypacService(adinfo, sourcePath); + + // } + // catch (Exception e) + // { + + + // PrintError(e.ToString()); + // HideProcessBar(); + + // return; + // } + + // AssetDatabase.Refresh(); + // HideProcessBar(); + // ShowTips("提示", "iOS端-" + JPService.info_plist_name + "引入成功"); + + } + public static void JoypacService(JPReleaseAreaType type, string sourcePath) + { + //if (!HasComponent(JPComponenetType.JoyPacAd)) + // return; + + + //bool isrewrite = true; // true=覆盖已存在的同名文件,false则反之 + + + //if (File.Exists(sourcePath) && targetPath != null) + //{ + // System.IO.File.Copy(sourcePath, targetPath, isrewrite); + //} + //else + //{ + // throw new Exception("please check '" + sourcePath + "' and '" + targetPath + "',Does it exist?"); + //} + + + + } + #region Unity UI 提示 + + /// + /// 长势进度条. + /// + /// 进度条中信息. + /// 当前进度. + public static void ShowProcessBar(string info, float progress) + { + EditorUtility.DisplayProgressBar("JOYPAC SDK", info, progress); + } + + /// + /// 关闭当前进度条. + /// + public static void HideProcessBar() + { + EditorUtility.ClearProgressBar(); + } + + /// + /// 展示提示. + /// + /// 标题. + /// 具体内容. + public static void ShowTips(string title, string content) + { + // 展示提示信息. + EditorUtility.DisplayDialog(title, content, "OK"); + } + + #endregion + + #region 文件夹处理相关 + + /// + /// 删除文件夹. + /// + /// 目录名. + private static void DeleteFolder(string dirPath) + { + var directionInfo = new DirectoryInfo(dirPath); + if (directionInfo.Exists) + { + directionInfo.Delete(true); + } + } + + + /// + /// 从源目录复制文件夹到目标目录. + /// + /// 源目录. + /// 目标目录. + private static void CopyFolder(string sourceDirectory, string targetDirectory) + { + try + { + // 先检查目标目录是否存在 + if (!Directory.Exists(targetDirectory)) + { + Directory.CreateDirectory(targetDirectory); + } + + var dir = new DirectoryInfo(sourceDirectory); + + // 获取目录下(不包含子目录)的文件和子目录 + var fileinfo = dir.GetFileSystemInfos(); + foreach (var i in fileinfo) + { + // 判断是否文件夹 + if (i is DirectoryInfo) + { + if (!Directory.Exists(Path.Combine(targetDirectory, i.Name))) + { + // 目标目录下不存在此文件夹即创建子文件夹 + Directory.CreateDirectory(Path.Combine(targetDirectory, i.Name)); + } + + // 递归调用复制子文件夹 + CopyFolder(i.FullName, Path.Combine(targetDirectory, i.Name)); + } + else + { + // 不是文件夹即复制文件,true表示可以覆盖同名文件 + File.Copy(i.FullName, Path.Combine(targetDirectory, i.Name), true); + } + } + + + } + catch (Exception ex) + { + PrintError(ex.ToString()); + } + } + + #endregion + #region Manifest文件处理 + + // push 在manifest中 application的tag. + private const string ManifestApplicationAdmobTag = "com.google.android.gms.ads.AD_MANAGER_APP"; + + // manifest目标路径. + private const string ManifestTargetPath = "Assets/Plugins/Android/AndroidManifest.xml"; + + // manifest目标绝对路径. + private static readonly string ManifestTargetAbsPath = Path.Combine(Application.dataPath, ManifestTargetPath); + + + + + + + private static void InsertAllowBackupTagToManifest(string manifestFilePath) + { + + UpdateXmlSingleNodeAttr( + manifestFilePath, "application", + "com.google.android.gms.ads.AD_MANAGER_APP", + "true", + delegate (UpdateXmlAttributeState + state, XmlElement element) + { + switch (state) + { + case UpdateXmlAttributeState.Insert: + element.SetAttribute("com.google.android.gms.ads.AD_MANAGER_APP", + "true"); + break; + case UpdateXmlAttributeState.DifferentValue: + case UpdateXmlAttributeState.HaveSameValue: + case UpdateXmlAttributeState.Fail: + // ignore + break; + } + }); + + + UpdateXmlSingleNodeAttr( + manifestFilePath, "application", + "tools:replace", + "android:value", + delegate (UpdateXmlAttributeState + state, XmlElement element) + { + switch (state) + { + case UpdateXmlAttributeState.Insert: + element.SetAttribute("replace", + + "android:value"); + break; + + + + } + }); + } + + // 插入网络配置文件. + private static void InsertNetConfig(string manifestFilePath) + { + // 插入NetConfig标签. + UpdateXmlSingleNodeAttr( + manifestFilePath, "application", + "android:networkSecurityConfig", + "@xml/net_config", + delegate (UpdateXmlAttributeState + state, XmlElement element) + { + switch (state) + { + case UpdateXmlAttributeState.Insert: + element.SetAttribute("networkSecurityConfig", + "http://schemas.android.com/apk/res/android", + "@xml/net_config"); + break; + case UpdateXmlAttributeState.DifferentValue: + case UpdateXmlAttributeState.HaveSameValue: + case UpdateXmlAttributeState.Fail: + // ignore + break; + } + }); + + // NetConfig replace 标签 + UpdateXmlSingleNodeAttr( + manifestFilePath, "application", + "tools:replace", + "android:networkSecurityConfig", + delegate (UpdateXmlAttributeState + state, XmlElement element) + { + switch (state) + { + case UpdateXmlAttributeState.Insert: + element.SetAttribute("replace", + "http://schemas.android.com/tools", + "@xml/net_config"); + break; + case UpdateXmlAttributeState.DifferentValue: + + var originAttrValue = element.GetAttribute("replace", "http://schemas.android.com/tools"); + var value = originAttrValue.Split(','); + var hasValue = false; + foreach (var s in value) + { + if (s == "android:networkSecurityConfig") + { + hasValue = true; + break; + } + } + + // 如果没有此值,在追加此值 + if (!hasValue) + { + element.SetAttribute("replace", + "http://schemas.android.com/tools", + originAttrValue + ",android:networkSecurityConfig"); + } + + break; + case UpdateXmlAttributeState.HaveSameValue: + case UpdateXmlAttributeState.Fail: + // ignore + break; + } + }); + } + + + + /// + /// 复制net_config.xml文件 + /// + private static void CopyNetConfig() + { + var netConfigTargetPath = Path.Combine(GetAndroidXmlPath(), "net_config.xml"); + var netConfigBackupPath = GetComponentDir(JPComponenetType.Core) + "/Plugins/Android/Xml/LG_net_config.xml"; + if (!File.Exists(netConfigTargetPath)) + { + File.Copy(netConfigBackupPath, netConfigTargetPath, true); + } + } + + /// + /// 获取android、xml所在目录. + /// + /// + private static string GetAndroidXmlPath() + { + var xmlPath = Path.Combine(GetAndroidResPath(), "xml"); + if (!Directory.Exists(xmlPath)) + { + Directory.CreateDirectory(xmlPath); + } + + return xmlPath; + } + + /// + /// 获取Android res 所在路径. + /// + /// Android res 目录. + private static string GetAndroidResPath() + { + var androidResPath = Path.Combine(Application.dataPath, "Plugins/Android/res"); + if (!Directory.Exists(androidResPath)) + { + Directory.CreateDirectory(androidResPath); + } + + return androidResPath; + } + + /// + /// manifest文件检查. + /// + /// manifest文件路径. + private static void AndroidSafeManifest(string manifestFilePath) + { + if (!File.Exists(manifestFilePath)) + { + // 文件不存在,将sdk内置默认的Manifest copy过去 + File.Copy( + Path.Combine(GetComponentDir(JPComponenetType.Core), + "Plugins/Android/Manifest/DefaultAndroidManifest.xml"), + manifestFilePath); + AssetDatabase.Refresh(); + + // 修改默认manifest中的默认包名,如果是ios平台获取的则是ios平台的包名。 + //var androidPackageName = Application.identifier; + //UpdateXmlSingleNodeAttr( + // manifestFilePath, "manifest", + // "package", + // androidPackageName, delegate (UpdateXmlAttributeState state, XmlElement element) + // { + // if (state == UpdateXmlAttributeState.Insert || state == UpdateXmlAttributeState.DifferentValue) + // { + // element.SetAttribute("package", androidPackageName); + // PrintDebug("Android Package Update Success : " + androidPackageName); + // } + // }); + } + } + + + + public enum UpdateXmlAttributeState + { + // 还没有此属性,插入此属性 + Insert, + + // 有不同的值 + DifferentValue, + + // 已经有了相同的值 + HaveSameValue, + + // 修改失败 + Fail, + } + + /// + /// 修改application的属性值. + /// + /// 文件路径. + /// 标签名称. + /// 属性名称. + /// 属性值. + /// 更新回调. + private static void UpdateXmlSingleNodeAttr(string filePath, + string label, string attrName, string attrValue, + Action updateCallback) + { + var xmlDocument = GetXmlDocument(filePath); + + XmlNode selectSingleNode; + if (xmlDocument.FirstChild.Name != label) + { + // 根结点不是manifest,则需要单独处理. + selectSingleNode = xmlDocument.SelectSingleNode("manifest"); + if (selectSingleNode != null) + { + var xmlNodeList = selectSingleNode.ChildNodes; + for (var i = xmlNodeList.Count - 1; i >= 0; i--) + { + var xmlNode = xmlNodeList[i]; + if (xmlNode.Name == label) + { + selectSingleNode = selectSingleNode.SelectSingleNode(label); + break; + } + } + } + } + else + { + selectSingleNode = xmlDocument.SelectSingleNode(label); + } + var hasUpdate = false; + if (selectSingleNode != null && typeof(XmlElement) == selectSingleNode.GetType()) + { + var xmlElement = (XmlElement)selectSingleNode; + var nameAttrValue = xmlElement.GetAttribute(attrName); + if (string.IsNullOrEmpty(nameAttrValue)) + { + hasUpdate = true; + // 插入标签 + updateCallback.Invoke(UpdateXmlAttributeState.Insert, xmlElement); + } + else + { + if (nameAttrValue == attrValue) + { + // 有此属性,值也相同 + hasUpdate = true; + updateCallback.Invoke(UpdateXmlAttributeState.HaveSameValue, xmlElement); + } + else + { + hasUpdate = true; + // 有此属性,但是值不同 + updateCallback.Invoke(UpdateXmlAttributeState.DifferentValue, xmlElement); + } + } + } + else + { + Debug.LogError("selectSingleNode is null..."); + updateCallback.Invoke(UpdateXmlAttributeState.Fail, null); + } + + if (hasUpdate) + { + XmlWriteToFile(xmlDocument, filePath); + } + + AssetDatabase.Refresh(); + + //try + //{ + // var dirInfo = new DirectoryInfo(dirPath); + // if (dirInfo.Exists) + // { + // var fileSystemInfos = dirInfo.GetFileSystemInfos(); + // foreach (var fileSystemInfo in fileSystemInfos) + // { + // if (fileSystemInfo is DirectoryInfo) + // { + // // 只处理目录. + // foreach (var s in iosPlatformWhiteList) + // { + // if (fileSystemInfo.Name.Contains(s)) + // { + // var replace = + // fileSystemInfo.FullName.Replace(Environment.CurrentDirectory + "/", ""); + // var assetImporter = AssetImporter.GetAtPath(replace); + + // if (assetImporter != null && assetImporter is PluginImporter importer) + // { + // importer.ClearSettings(); + // importer.SetCompatibleWithAnyPlatform(false); + // importer.SetCompatibleWithPlatform(BuildTarget.iOS, true); + // importer.SaveAndReimport(); + // } + // } + // } + + // Modify_iOSFolderPlatformType(fileSystemInfo.FullName); + // } + // } + // } + //} + //catch (Exception e) + //{ + // PrintError(e.ToString()); + // HideProcessBar(); + //} + + } + + private static void UpdateXmlSingle(string filePath + ) + + { + XmlDocument xmlDocument = GetXmlDocument(filePath); + + var admob = xmlDocument.CreateElement("meta"); + admob.SetAttribute(ManifestApplicationAdmobTag, "1111111"); + var node_manifest = xmlDocument["manifest"]; + var node_application = node_manifest["application"]; + node_application.AppendChild(admob); + + + AssetDatabase.Refresh(); + } + private static void InsertAdXmlToApplication(JPAdNType JPAdNType) + { + var filePath = GetAndroidManifestFilePath(); + + var adnConfigFile = Path.Combine( + GetComponentDir(JPComponenetType.JoyPacAd) + "/Plugins/Android/ADN", + JPAdNType + "/Manifest/" + + JPAdNType + "_AndroidManifest.xml"); + + if (!File.Exists(adnConfigFile)) + { + // 文件不存在说明,adn不需要xml的配置. + return; + } + + var xmlDocument = GetXmlDocument(filePath); + + // 选择xml中的特定节点 + var manifestNode = xmlDocument.SelectSingleNode("manifest"); + if (manifestNode != null) + { + var applicationNode = manifestNode.SelectSingleNode("application"); + if (applicationNode != null) + { + // 先移除掉旧配置. + RemoveAdXmlFromApplication(JPAdNType); + // 添加新配置. + var adnApplicationNode = GetApplicationNode(adnConfigFile); + if (adnApplicationNode != null) + { + var xmlNodeList = adnApplicationNode.ChildNodes; + for (var i = 0; i < xmlNodeList.Count; i++) + { + var xmlNode = xmlNodeList[i]; + var importNode = xmlDocument.ImportNode(xmlNode, true); + applicationNode.AppendChild(importNode); + } + } + } + } + + XmlWriteToFile(xmlDocument, filePath); + } + + /// + /// 获取application节点. + /// + /// 文件路径. + /// xml节点. + private static XmlNode GetApplicationNode(string filePath) + { + var xmlDocument = GetXmlDocument(filePath); + if (xmlDocument != null) + { + var manifestNode = xmlDocument.SelectSingleNode("manifest"); + if (manifestNode != null) + { + var applicationNode = manifestNode.SelectSingleNode("application"); + if (applicationNode != null) + { + return applicationNode; + } + } + } + + return null; + } + + /// + /// 获取manifest节点. + /// + /// + /// + private static XmlNode GetManifestNode(string filePath) + { + var xmlDocument = GetXmlDocument(filePath); + if (xmlDocument != null) + { + var manifestNode = xmlDocument.SelectSingleNode("manifest"); + return manifestNode; + } + + return null; + } + + private static XmlNode GetManifestTargetNode(string filePath, string nodeName) + { + var xmlDocument = GetXmlDocument(filePath); + if (xmlDocument != null) + { + var selectSingleNode = xmlDocument.SelectSingleNode(nodeName); + if (selectSingleNode == null) + { + var manifestNode = xmlDocument.SelectSingleNode("manifest"); + if (manifestNode != null) + { + var applicationNode = manifestNode.SelectSingleNode(nodeName); + if (applicationNode != null) + { + return applicationNode; + } + } + } + else + { + return selectSingleNode; + } + } + + return null; + } + + /// + /// 通过文件读取xmlDocument. + /// + /// xml文件路径. + /// XmlDocument + private static XmlDocument GetXmlDocument(string filePath) + { + var xmlDocument = new XmlDocument(); + + // 读取xml的配置对象 + var xmlReaderSettings = new XmlReaderSettings(); + + // xml读取类 + var xmlReader = XmlReader.Create(filePath, xmlReaderSettings); + + xmlDocument.Load(xmlReader); + xmlReader.Close(); + return xmlDocument; + } + + /// + /// 移除广告存在的配置. + /// + /// 广告类型. + private static void RemoveAdXmlFromApplication(JPAdNType JPAdNType) + { + var filePath = Path.Combine(Application.dataPath, ManifestTargetPath); + if (!File.Exists(filePath)) + { + // 文件不存在,就不做移除操作. + return; + } + + var xmlDocument = GetXmlDocument(filePath); + + var hasUpdate = false; + + // 选择xml中的特定节点 + var manifestNode = xmlDocument.SelectSingleNode("manifest"); + if (manifestNode != null) + { + var applicationNode = manifestNode.SelectSingleNode("application"); + if (applicationNode != null) + { + // 是否开始移除子xml + var startRemoveChild = false; + // 是否结束移除子xml + var endRemoveChild = false; + + var applicationNodeChildNodes = applicationNode.ChildNodes; + + var needRemoveXmlNode = new List(); + + for (var i = 0; i < applicationNodeChildNodes.Count; i++) + { + var applicationNodeChildNode = applicationNodeChildNodes[i]; + if (applicationNodeChildNode.GetType() == typeof(XmlComment)) + { + var currentAdComment = (XmlComment)applicationNodeChildNode; + if (currentAdComment.Value.Contains(JPAdNType + "_Start")) + { + // 注释的开始 + startRemoveChild = true; + } + else if (currentAdComment.Value.Contains(JPAdNType + "_End")) + { + // 注释的结尾 + endRemoveChild = true; + } + } + + if (startRemoveChild) + { + if (endRemoveChild) + { + needRemoveXmlNode.Add(applicationNodeChildNode); + break; + } + + needRemoveXmlNode.Add(applicationNodeChildNode); + } + } + + // 处理需要移除的child node + foreach (var xmlNode in needRemoveXmlNode) + { + hasUpdate = true; + applicationNode.RemoveChild(xmlNode); + } + } + } + + if (hasUpdate) + { + XmlWriteToFile(xmlDocument, filePath); + } + } + + /// + /// 根据tag移除manifest中的节点. + /// + /// 开始tag. + /// 结束tag. + private static void RemoveManifestNodeByTag(string startTag, string endTag) + { + var filePath = Path.Combine(Application.dataPath, ManifestTargetPath); + if (!File.Exists(filePath)) + { + // 文件不存在,就不做移除操作. + return; + } + + var xmlDocument = GetXmlDocument(filePath); + + var hasUpdate = false; + + // 选择xml中的特定节点 + var manifestNode = xmlDocument.SelectSingleNode("manifest"); + if (manifestNode != null) + { + // 是否开始移除子xml + var startRemoveChild = false; + // 是否结束移除子xml + var endRemoveChild = false; + + var manifestNodeChildNodes = manifestNode.ChildNodes; + + var needRemoveXmlNode = new List(); + + for (var i = 0; i < manifestNodeChildNodes.Count; i++) + { + var manifestNodeChildNode = manifestNodeChildNodes[i]; + if (manifestNodeChildNode.GetType() == typeof(XmlComment)) + { + var currentAdComment = (XmlComment)manifestNodeChildNode; + if (currentAdComment.Value.Contains(startTag)) + { + // 注释的开始 + startRemoveChild = true; + } + else if (currentAdComment.Value.Contains(endTag)) + { + // 注释的结尾 + endRemoveChild = true; + } + } + + if (startRemoveChild) + { + if (endRemoveChild) + { + needRemoveXmlNode.Add(manifestNodeChildNode); + break; + } + + needRemoveXmlNode.Add(manifestNodeChildNode); + } + } + + // 处理需要移除的child node + foreach (var xmlNode in needRemoveXmlNode) + { + hasUpdate = true; + manifestNode.RemoveChild(xmlNode); + } + } + + if (hasUpdate) + { + XmlWriteToFile(xmlDocument, filePath); + } + } + + /// + /// 将xml写入到文件中. + /// + /// document. + /// 文件目标路径. + private static void XmlWriteToFile(XmlNode xmlDocument, string filePath) + { + // 内存中保存的流 + var memoryStream = new MemoryStream(); + + // 文本写入对象 + var xmlWriter = new XmlTextWriter(memoryStream, Encoding.UTF8); + xmlWriter.Indentation = 4; + xmlWriter.Formatting = Formatting.Indented; + + // 文档内容写入到写入对象中 + xmlDocument.WriteContentTo(xmlWriter); + xmlWriter.Close(); + + File.WriteAllBytes(filePath, memoryStream.ToArray()); + memoryStream.Dispose(); + AssetDatabase.Refresh(); + } + + /// + /// 获取manifest文件路径. + /// + /// manifest文件路径. + private static string GetAndroidManifestFilePath() + { + var androidFolder = Path.Combine(Application.dataPath, "Plugins/Android"); + if (!Directory.Exists(androidFolder)) + { + Directory.CreateDirectory(androidFolder); + } + + return Path.Combine(androidFolder, "AndroidManifest.xml"); + } + + /// + /// 插入权限xml到manifest文件中. + /// + + + #endregion + + #region gradle文件处理 + + private const string GradleBuildScriptTag = "buildscript {"; + private const string GradleAllProjectsTag = "allprojects {"; + private const string GradleApplicationPluginTag = "apply plugin: 'com.android.application'"; + private const string GradleMinSdkVersionTag = "minSdkVersion"; + private const string GradleMultiDexEnableTag = "multiDexEnabled"; + public const string GradleAndroidTag = "android {"; + private const string GradleDefaultConfigTag = "defaultConfig {"; + + /// + /// 插入gradle中的依赖内容. + /// + /// 需要插入的文件路径. + public static void InsertDependenciesToGradle(string insertFilePath) + { + if (!File.Exists(insertFilePath)) + { + // 需要插入的文件不存在,则直接返回 + return; + } + + var gradleFilePath = GetMainTemplateGradleFilePath(); + + // 需要插入内容 + var insertLines = File.ReadAllLines(insertFilePath); + + // 先移除已有的依赖 + RemoveGradleConfig(gradleFilePath, insertFilePath); + + var allLines = File.ReadAllLines(gradleFilePath); + + // 新文本内容存储列表 + var newLines = new List(); + + // 此时已经移除 + foreach (var lineText in allLines) + { + // 依赖的结尾标记 + if (lineText.Contains("**DEPS**}")) + { + // 插入文本前后添加两个空行 + newLines.AddRange(insertLines); + } + + newLines.Add(lineText); + } + + // 重新写入到文件中 + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + + /// + /// 移除gradle中的依赖. + /// + /// gradle文件路径. + /// 需要移除的文件路径. + public static void RemoveGradleConfig(string gradleFilePath, string removeFilePath) + { + if (!File.Exists(gradleFilePath)) + { + // 文件不存在,则不需要移除 + return; + } + + if (!File.Exists(removeFilePath)) + { + // 文件不存在,不需要删除 + return; + } + + // 需要插入内容 + var insertLines = File.ReadAllLines(removeFilePath, Encoding.UTF8); + if (insertLines.Length < 2) + { + PrintError(removeFilePath + "文件中的内容不规范,请检查需要插入的文件."); + return; + } + + var startTag = insertLines[0]; + var endTag = insertLines[insertLines.Length - 1]; + + // 所有行数 + var allLines = File.ReadAllLines(gradleFilePath, Encoding.UTF8); + // 移除后的文本列表 + var newLines = new List(); + + // 开始移除标记 + var startRemove = false; + // 结束移除标记 + var endRemove = false; + + foreach (var lineText in allLines) + { + if (lineText.Contains(startTag)) + { + startRemove = true; + } + + if (lineText.Contains(endTag)) + { + endRemove = true; + } + + if (startRemove) + { + // 开始标记和结束标记都不做文本添加,结束标记触发后,重制状态继续添加文本。 + if (endRemove) + { + startRemove = false; + endRemove = false; + } + } + else + { + newLines.Add(lineText); + } + } + + // 重新写入到文件中 + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + + + public static void CheckoutDevKitGradleFile() + { + SafeGradleFile(); + + + + } + + public static void CheckGradleFile() + { + SafeGradleFile(); + + // 插入Core模块需要的依赖 + InsertDependenciesToGradle(GetComponentDir(JPComponenetType.Core) + + "/Plugins/Android/Gradle/LG_Core_Config_Template.gradle"); + + + // 插入MultiDex依赖 + InsertDependenciesToGradle(GetComponentDir(JPComponenetType.Core) + + "/Plugins/Android/Gradle/LG_Multidex_Config_Template.gradle"); + + + // 先检查是否有buildScript、allProjects + CheckGradleBuildScriptTag(GetMainTemplateGradleFilePath()); + CheckGradleAllProjectsTag(GetMainTemplateGradleFilePath()); + // 最小sdk版本检查 + CheckGradleMinSdkVersion(GetMainTemplateGradleFilePath()); + //multiDex + CheckGradleMultiDex(GetMainTemplateGradleFilePath()); + + // 检查mainTemplate.gradle中的maven + CheckGradleMaven( + GetMainTemplateGradleFilePath(), "repositories {", Path.Combine( + GetComponentDir(JPComponenetType.Core) + "/Plugins/Android/Gradle", + "LG_Maven_Config_Template.gradle")); + + // 先检查是否有buildScript、allProjects + CheckGradleBuildScriptTag(GetLauncherTemplateGradleFilePath()); + CheckGradleAllProjectsTag(GetLauncherTemplateGradleFilePath()); + // 最小sdk版本检查 + CheckGradleMinSdkVersion(GetLauncherTemplateGradleFilePath()); + //multiDex + CheckGradleMultiDex(GetLauncherTemplateGradleFilePath()); + + // 检查launcher.gradle中的 maven + CheckGradleMaven( + GetLauncherTemplateGradleFilePath(), "repositories {", Path.Combine( + GetComponentDir(JPComponenetType.Core) + "/Plugins/Android/Gradle", + "LG_Maven_Config_Template.gradle")); + + // 检查不同Unity版本、处理.gradle中不同的aapt规则 + CheckGradleAapt(); + } + + /// + /// 检查gradle中的aapt. + /// + private static void CheckGradleAapt() + { +#if UNITY_2020_1_OR_NEWER + // 处理 2020及以上版本 + HandleGradleAapt(GetMainTemplateGradleFilePath(),GetComponentDir(JPComponenetType.Core) + + "/Plugins/Android/Gradle/LG_2020_OR_NEW_AAPT_Config_Template.gradle"); + + HandleGradleAapt(GetLauncherTemplateGradleFilePath(),GetComponentDir(JPComponenetType.Core) + + "/Plugins/Android/Gradle/LG_2020_OR_NEW_AAPT_Config_Template.gradle"); +#else + // 处理 2020及以下版本 + HandleGradleAapt(GetMainTemplateGradleFilePath(), GetComponentDir(JPComponenetType.Core) + + "/Plugins/Android/Gradle/LG_2020_OR_OLD_AAPT_MainTemplate.gradle"); + + HandleGradleAapt(GetLauncherTemplateGradleFilePath(), GetComponentDir(JPComponenetType.Core) + + "/Plugins/Android/Gradle/LG_2020_OR_OLD_AAPT_LauncherTemplate.gradle"); +#endif + } + + private static void HandleGradleAapt(string gradleFilePath, string insertFilePath) + { + if (!File.Exists(gradleFilePath)) + { + // 不存在此文件,直接返回 + return; + } + + if (!File.Exists(insertFilePath)) + { + // 需要插入的文件路径不存在,直接返回 + return; + } + + // 先移除已有的配置 + RemoveGradleConfig(gradleFilePath, insertFilePath); + + // 插入预置的配置 + GradleInsertTagAfter(gradleFilePath, insertFilePath, GradleAndroidTag); + } + + private static void CheckGradleMinSdkVersion(string gradleFilePath) + { + if (HasGradleTagConfigFile(gradleFilePath, GradleMinSdkVersionTag)) + { + // 有此tag,取出来对比一下,是否大于等于19 + // 没有此tag,直接插入此 + var allLines = File.ReadAllLines(gradleFilePath); + // 新文本内容存储列表 + var newLines = new List(); + // 此时已经移除 + foreach (var t in allLines) + { + var lineText = t; + // 依赖的结尾标记 + if (lineText.Contains(GradleMinSdkVersionTag)) + { + var textArray = lineText.Split(' '); + if (textArray.Length > 0) + { + var text = textArray[textArray.Length - 1]; + try + { + var value = int.Parse(text); + if (value < 19) + { + lineText = " minSdkVersion 19"; + } + } + catch (Exception e) + { + // 转换失败,直接插入新的文本 + lineText = " minSdkVersion 19"; + } + } + } + + newLines.Add(lineText); + } + + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + else + { + // 没有此tag,直接插入 + var allLines = File.ReadAllLines(gradleFilePath); + // 新文本内容存储列表 + var newLines = new List(); + // 此时已经移除 + foreach (var lineText in allLines) + { + newLines.Add(lineText); + // 依赖的结尾标记 + if (lineText.Contains(GradleDefaultConfigTag)) + { + // 插入文本前后添加两个空行 + newLines.Add(" minSdkVersion 19"); + } + } + + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + } + + private static void CheckGradleMultiDex(string gradleFilePath) + { + if (HasGradleTagConfigFile(gradleFilePath, GradleMultiDexEnableTag)) + { + // 有此tag,取出来对比一下,是否大于等于19 + // 没有此tag,直接插入此 + var allLines = File.ReadAllLines(gradleFilePath); + // 新文本内容存储列表 + var newLines = new List(); + // 此时已经移除 + foreach (var t in allLines) + { + var lineText = t; + // 依赖的结尾标记 + if (lineText.Contains(GradleMultiDexEnableTag)) + { + var textArray = lineText.Split(' '); + if (textArray.Length > 0) + { + var text = textArray[textArray.Length - 1]; + try + { + var value = bool.Parse(text); + if (!value) + { + lineText = " multiDexEnabled true"; + } + } + catch (Exception e) + { + // 转换失败,直接插入新的文本 + lineText = " multiDexEnabled true"; + } + } + } + + newLines.Add(lineText); + } + + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + else + { + // 没有此tag,直接插入 + var allLines = File.ReadAllLines(gradleFilePath); + // 新文本内容存储列表 + var newLines = new List(); + // 此时已经移除 + foreach (var lineText in allLines) + { + newLines.Add(lineText); + // 依赖的结尾标记 + if (lineText.Contains(GradleDefaultConfigTag)) + { + // 插入文本前后添加两个空行 + newLines.Add(" multiDexEnabled true"); + } + } + + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + } + + private static void CheckGradleBuildScriptTag(string gradleFilePath) + { + if (!File.Exists(gradleFilePath)) + { + // 不存在此文件,直接返回 + return; + } + + // 没有此配置直接写入 + if (!HasGradleTagConfigFile(gradleFilePath, GradleBuildScriptTag)) + { + var insertFilePath = GetComponentDir(JPComponenetType.Core) + + "/Plugins/Android/Gradle/LG_BuildScript_Config_LauncherTemplate.gradle"; + GradleInsertTagBefore(gradleFilePath, insertFilePath, GradleApplicationPluginTag); + } + } + + private static void CheckGradleAllProjectsTag(string gradleFilePath) + { + if (!File.Exists(gradleFilePath)) + { + // 不存在此文件,直接返回 + return; + } + + // 没有此配置直接写入 + if (!HasGradleTagConfigFile(gradleFilePath, GradleAllProjectsTag)) + { + var insertFilePath = GetComponentDir(JPComponenetType.Core) + + "/Plugins/Android/Gradle/LG_AllProjects_Config_LauncherTemplate.gradle"; + GradleInsertTagBefore(gradleFilePath, insertFilePath, GradleApplicationPluginTag); + } + } + + public static void GradleInsertTagAfter(string gradleFilePath, string insertFilePath, string tag) + { + SafeGradleFile(); + // 需要插入内容 + var insertLines = File.ReadAllLines(insertFilePath); + var allLines = File.ReadAllLines(gradleFilePath); + // 新文本内容存储列表 + var newLines = new List(); + // 此时已经移除 + foreach (var lineText in allLines) + { + newLines.Add(lineText); + + // 依赖的结尾标记 + if (lineText.Contains(tag)) + { + // 插入文本前后添加两个空行 + newLines.AddRange(insertLines); + } + } + + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + + private static void GradleInsertTagBefore(string gradleFilePath, string insertFilePath, string tag) + { + SafeGradleFile(); + // 需要插入内容 + var insertLines = File.ReadAllLines(insertFilePath); + var allLines = File.ReadAllLines(gradleFilePath); + // 新文本内容存储列表 + var newLines = new List(); + // 此时已经移除 + foreach (var lineText in allLines) + { + // 依赖的结尾标记 + if (lineText.Contains(tag)) + { + // 插入文本前后添加两个空行 + newLines.AddRange(insertLines); + } + + newLines.Add(lineText); + } + + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + + private static void CheckGradleMaven( + string gradleFilePath, + string mavenTag, + string tempMavenGradleFile) + { + // 先移除配置内容 + RemoveGradleConfig(gradleFilePath, tempMavenGradleFile); + + var allLines = File.ReadAllLines(gradleFilePath, Encoding.UTF8); + var insertLines = File.ReadAllLines(tempMavenGradleFile, Encoding.UTF8); + var newLines = new List(); + foreach (var lineText in allLines) + { + if (lineText.Contains(mavenTag)) + { + newLines.Add(lineText); + newLines.AddRange(insertLines); + } + else + { + newLines.Add(lineText); + } + } + + File.WriteAllLines(gradleFilePath, newLines, Encoding.UTF8); + AssetDatabase.Refresh(); + } + + /// + /// 检查gradle文件. + /// + private static void SafeGradleFile() + { + if (!File.Exists(GetMainTemplateGradleFilePath())) + { + var mainTemplateGradleTempDir = + Path.Combine(GetComponentDir( + JPComponenetType.Core) + "/Plugins/Android/Gradle", + "LG_Default_MainTemplate.gradle"); + + // 将默认文件Copy到目标目录 + File.Copy(mainTemplateGradleTempDir, GetMainTemplateGradleFilePath()); + } + + // launcherTemplate + var launcherGradleFilePath = Path.Combine(Application.dataPath, "Plugins/Android/launcherTemplate.gradle"); + if (!File.Exists(launcherGradleFilePath)) + { + var launcherGradleTempDir = + Path.Combine(GetComponentDir( + JPComponenetType.Core) + "/Plugins/Android/Gradle", + "LG_Default_LauncherTemplate.gradle"); + + var targetFilePath = Path.Combine(Application.dataPath, "Plugins/Android/launcherTemplate.gradle"); + + File.Copy(launcherGradleTempDir, targetFilePath); + } + } + + + /// + /// gradle文件中是否有配置. + /// + /// 是否有配置. + private static bool HasGradleTagConfigFile(string gradleFilePath, string tag) + { + if (!File.Exists(gradleFilePath)) + { + return false; + } + + // 遍历检查是否有某个配置 + var allLines = File.ReadAllLines(gradleFilePath, Encoding.UTF8); + + return allLines.Any(lineText => lineText.Contains(tag)); + } + + /// + /// 获取mainTemplate.gradle文件存在的路径. + /// + /// mainTemplate存在的路径. + public static string GetMainTemplateGradleFilePath() + { + var androidFolder = Path.Combine(Application.dataPath, "Plugins/Android"); + if (!Directory.Exists(androidFolder)) + { + Directory.CreateDirectory(androidFolder); + } + + return Path.Combine(androidFolder, "mainTemplate.gradle"); + } + + /// + /// 获取launcherTemplate.gradle的文件路径. + /// + /// launcherTemplate.gradle的文件路径 + public static string GetLauncherTemplateGradleFilePath() + { + var androidFolder = Path.Combine(Application.dataPath, "Plugins/Android"); + if (!Directory.Exists(androidFolder)) + { + Directory.CreateDirectory(androidFolder); + } + + return Path.Combine(androidFolder, "launcherTemplate.gradle"); + } + + #endregion + + #region 修改文件夹为iOS平台类型 + + /// + /// 平台类型需要设置为iOS的文件夹,后面有其他需要修改平台类型的文件,也需要加入到此白名单中. + /// + private static string[] iosPlatformWhiteList = + { + ".framework", ".bundle", ".a" + }; + + /// + /// 修改某个目录下iOS文件平台类型. + /// + /// 目录名称. + private static void Modify_iOSFolderPlatformType(string dirPath) + { + try + { + var dirInfo = new DirectoryInfo(dirPath); + if (dirInfo.Exists) + { + var fileSystemInfos = dirInfo.GetFileSystemInfos(); + foreach (var fileSystemInfo in fileSystemInfos) + { + if (fileSystemInfo is DirectoryInfo) + { + // 只处理目录. + foreach (var s in iosPlatformWhiteList) + { + if (fileSystemInfo.Name.Contains(s)) + { + var replace = + fileSystemInfo.FullName.Replace(Environment.CurrentDirectory + "/", ""); + var assetImporter = AssetImporter.GetAtPath(replace); + + if (assetImporter != null && assetImporter is PluginImporter importer) + { + importer.ClearSettings(); + importer.SetCompatibleWithAnyPlatform(false); + importer.SetCompatibleWithPlatform(BuildTarget.iOS, true); + importer.SaveAndReimport(); + } + } + } + + Modify_iOSFolderPlatformType(fileSystemInfo.FullName); + } + } + } + } + catch (Exception e) + { + PrintError(e.ToString()); + HideProcessBar(); + } + } + + #endregion + + /// + /// 打印错误信息. + /// + /// + private static void PrintError(string errorMsg) + { + Debug.LogError(errorMsg); + // 报错时关闭进度弹窗. + HideProcessBar(); + } + + /// + /// 打印调试信息. + /// + /// 调试信息. + private static void PrintDebug(string msg) + { + Debug.Log(msg); + } + + + + + +} + +public class JPService +{ + public const string info_target_path = "JoyPacSDK/JoyPacAd/JoyPacAd"; + public const string info_plist_name = "JoypacService-info.plist"; +} + +#endif \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/JPPackageManager.cs.meta b/popcorn/Assets/JoyPacSDK/Core/JPPackageManager.cs.meta new file mode 100644 index 00000000..29d46f2b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/JPPackageManager.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b90d95f8c95bf43099eb1ff2b7cb1d2f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins.meta new file mode 100644 index 00000000..f4541476 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a052c60cad40a48ee9a9e862b6afc932 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android.meta new file mode 100644 index 00000000..b129e61a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e84a02600a1be4951b8f9a3c5b78b1c1 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates.meta new file mode 100644 index 00000000..56dcf263 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e236f28c5d61e4504917243ce451b6f5 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates/libTemplate.gradle b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates/libTemplate.gradle new file mode 100755 index 00000000..e291dcc1 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates/libTemplate.gradle @@ -0,0 +1,28 @@ +apply plugin: 'android-library' + +dependencies { + implementation fileTree(dir: 'bin', include: ['*.jar']) + implementation fileTree(dir: 'libs', include: ['*.jar']) +} + +android { + sourceSets { + main { + manifest.srcFile 'AndroidManifest.xml' + //java.srcDirs = ['src'] + res.srcDirs = ['res'] + assets.srcDirs = ['assets'] + jniLibs.srcDirs = ['libs'] + } + } + + compileSdkVersion 30 + buildToolsVersion '30.0.0' + defaultConfig { + targetSdkVersion 30 + } + + lintOptions { + abortOnError false + } +} diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates/libTemplate.gradle.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates/libTemplate.gradle.meta new file mode 100644 index 00000000..92260143 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/GradleTemplates/libTemplate.gradle.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d383d27ad61c74637931ef56c1065bb8 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/JoyPacAndroidManifest.xml b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/JoyPacAndroidManifest.xml new file mode 100644 index 00000000..538888e2 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/JoyPacAndroidManifest.xml @@ -0,0 +1,13 @@ + + + + + + + + + + \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/JoyPacAndroidManifest.xml.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/JoyPacAndroidManifest.xml.meta new file mode 100644 index 00000000..a0443f95 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/JoyPacAndroidManifest.xml.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 45b8ab1dd87174e40bc1936d94e2e7c0 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/baseProjectTemplate.gradle b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/baseProjectTemplate.gradle new file mode 100755 index 00000000..304bf510 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/baseProjectTemplate.gradle @@ -0,0 +1,31 @@ +// GENERATED BY UNITY. REMOVE THIS COMMENT TO PREVENT OVERWRITING WHEN EXPORTING AGAIN + +allprojects { + buildscript { + repositories {**ARTIFACTORYREPOSITORY** + google() + jcenter() + } + + dependencies { + // If you are changing the Android Gradle Plugin version, make sure it is compatible with the Gradle version preinstalled with Unity + // See which Gradle version is preinstalled with Unity here https://docs.unity3d.com/Manual/android-gradle-overview.html + // See official Gradle and Android Gradle Plugin compatibility table here https://developer.android.com/studio/releases/gradle-plugin#updating-gradle + // To specify a custom Gradle version in Unity, go do "Preferences > External Tools", uncheck "Gradle Installed with Unity (recommended)" and specify a path to a custom Gradle version + classpath 'com.android.tools.build:gradle:4.0.1' + **BUILD_SCRIPT_DEPS** + } + } + + repositories {**ARTIFACTORYREPOSITORY** + google() + jcenter() + flatDir { + dirs "${project(':unityLibrary').projectDir}/libs" + } + } +} + +task clean(type: Delete) { + delete rootProject.buildDir +} diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/baseProjectTemplate.gradle.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/baseProjectTemplate.gradle.meta new file mode 100644 index 00000000..51dafea3 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/baseProjectTemplate.gradle.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 0dc96621f54d94a5c8ccd8af22acdb3f +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/gradleTemplate.properties b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/gradleTemplate.properties new file mode 100755 index 00000000..8491de2e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/gradleTemplate.properties @@ -0,0 +1,6 @@ +org.gradle.jvmargs=-Xmx**JVM_HEAP_SIZE**M +org.gradle.parallel=true +android.enableR8=false +unityStreamingAssets=.unity3d**STREAMING_ASSETS** + +**ADDITIONAL_PROPERTIES** diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/gradleTemplate.properties.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/gradleTemplate.properties.meta new file mode 100644 index 00000000..ddd6d233 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/gradleTemplate.properties.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 93d628c89a08f4612aab7a8133cddf2a +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/joypac.keystore b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/joypac.keystore new file mode 100644 index 00000000..3577f918 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/joypac.keystore differ diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/joypac.keystore.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/joypac.keystore.meta new file mode 100644 index 00000000..fcf100d4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/joypac.keystore.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 771db4212b3fd4cb695a9e9514dc33dd +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/launcherTemplate.gradle b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/launcherTemplate.gradle new file mode 100755 index 00000000..4a2880f5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/launcherTemplate.gradle @@ -0,0 +1,84 @@ +// GENERATED BY UNITY. REMOVE THIS COMMENT TO PREVENT OVERWRITING WHEN EXPORTING AGAIN + +apply plugin: 'com.android.application' + +dependencies { + implementation project(':unityLibrary') + } + +android { + + compileSdkVersion 30 + buildToolsVersion '30.0.0' + + + compileOptions { + sourceCompatibility JavaVersion.VERSION_1_8 + targetCompatibility JavaVersion.VERSION_1_8 + } + + defaultConfig { + multiDexEnabled true + minSdkVersion 19 + targetSdkVersion 30 + applicationId '**APPLICATIONID**' + ndk { + abiFilters **ABIFILTERS** + } + versionCode **VERSIONCODE** + versionName '**VERSIONNAME**' + } + + aaptOptions { + noCompress = ['.ress', '.resource', '.obb'] + unityStreamingAssets.tokenize(', ') + ignoreAssetsPattern = "!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~" + }**SIGN** + + lintOptions { + abortOnError false + } + + buildTypes { + debug { + minifyEnabled **MINIFY_DEBUG** + + proguardFiles getDefaultProguardFile('proguard-android.txt')**SIGNCONFIG** + jniDebuggable true + } + release { + minifyEnabled **MINIFY_RELEASE** + + proguardFiles getDefaultProguardFile('proguard-android.txt')**SIGNCONFIG** + } + }**PACKAGING_OPTIONS****SPLITS** +**BUILT_APK_LOCATION** + bundle { + language { + enableSplit = true + } + density { + enableSplit = true + } + abi { + enableSplit = true + } + } +}**SPLITS_VERSION_CODE****LAUNCHER_SOURCE_BUILD_SETUP** + + +tasks.whenTaskAdded { task -> + if (task.name.startsWith("bundle")) { + def renameTaskName = "rename${task.name.capitalize()}Aab" + def flavor = task.name.substring("bundle".length()).uncapitalize() + tasks.create(renameTaskName, Copy) { + def path = "${buildDir}/outputs/bundle/${flavor}/" + from(path) + include "launcher-release.aab" + destinationDir file("${buildDir}/outputs/bundle/${flavor}/") + rename "launcher-release.aab", "launcher.aab" + } + + task.finalizedBy(renameTaskName) + } +} + diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/launcherTemplate.gradle.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/launcherTemplate.gradle.meta new file mode 100644 index 00000000..75a365dc --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/launcherTemplate.gradle.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 76cb5e5705e544c37ab3a220df5a76e2 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/mainTemplate.gradle b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/mainTemplate.gradle new file mode 100755 index 00000000..82fffae5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/mainTemplate.gradle @@ -0,0 +1,55 @@ + +apply plugin: 'com.android.library' + +buildscript { + repositories { + + google() + jcenter() + } + + dependencies { + classpath 'com.android.tools.build:gradle:4.0.1' + +**BUILD_SCRIPT_DEPS**} +} + + +dependencies { + implementation fileTree(dir: 'libs', include: ['*.jar']) + implementation 'org.jetbrains.kotlin:kotlin-stdlib:1.3.72' +**DEPS**} + +android { + compileSdkVersion 30 + buildToolsVersion '30.0.0' + + compileOptions { + sourceCompatibility JavaVersion.VERSION_1_8 + targetCompatibility JavaVersion.VERSION_1_8 + } + + defaultConfig { + multiDexEnabled true + minSdkVersion **MINSDKVERSION** + targetSdkVersion **TARGETSDKVERSION** + ndk { + abiFilters **ABIFILTERS** + } + versionCode **VERSIONCODE** + versionName '**VERSIONNAME**' + consumerProguardFiles 'proguard-unity.txt'**USER_PROGUARD** + } + + lintOptions { + abortOnError false + } + + aaptOptions { + noCompress = ['.ress', '.resource', '.obb'] + unityStreamingAssets.tokenize(', ') + ignoreAssetsPattern = "!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~" + }**PACKAGING_OPTIONS** +}**REPOSITORIES** +**IL_CPP_BUILD_SETUP** +**SOURCE_BUILD_SETUP** +**EXTERNAL_SOURCES** diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/mainTemplate.gradle.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/mainTemplate.gradle.meta new file mode 100644 index 00000000..91d6c3eb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/mainTemplate.gradle.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: bd9f9196c246640efb6d87fab88da4a9 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/network_security_config.xml b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/network_security_config.xml new file mode 100644 index 00000000..dca93c07 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/network_security_config.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/network_security_config.xml.meta b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/network_security_config.xml.meta new file mode 100644 index 00000000..4b15dc6c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/Plugins/Android/network_security_config.xml.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 5b0ede50790ac4ebf83cd818fed564a2 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/StringKey.meta b/popcorn/Assets/JoyPacSDK/Core/StringKey.meta new file mode 100644 index 00000000..42d3e6eb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/StringKey.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bade0f357f20a4eb3b684ca869d45be1 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Core/StringKey/StringKeyManger.cs b/popcorn/Assets/JoyPacSDK/Core/StringKey/StringKeyManger.cs new file mode 100644 index 00000000..35a6e878 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/StringKey/StringKeyManger.cs @@ -0,0 +1,216 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using Newtonsoft.Json; +using System; +using System.IO; +using Newtonsoft.Json.Linq; +using System.Text; +using UnityEngine.Networking; + +public class StringKeyManger +{ + + +#if UNITY_IOS + public const string ENVIRONMEN = "iOS"; +#elif UNITY_ANDROID + public const string ENVIRONMEN = "Android"; +#elif UNITY_EDITOR + public const string ENVIRONMEN = "Editor"; +#endif + + + private StringKeyManger() { } + public static readonly StringKeyManger Instance = new StringKeyManger(); + private readonly string fp; + + + public const string path = "StringKey_" + ENVIRONMEN + ".json"; + + public const string BuildPath = "BuildStringKey_" + ENVIRONMEN + ".json"; + + public string BuildJsonPath = Application.dataPath + "/JoyPacSDK/BuildString/" + BuildPath; + public bool isHaveAdjustEvent = false; + public bool isHaveUmeng = false; + public bool isHaveJoypacSDK = false; + + public bool isUndateStringKey = false; + + + +#if UNITY_IPHONE + public string JsonPath = Application.streamingAssetsPath + "/" + path; //获取文件路径 + + + +#elif UNITY_ANDROID + public const string JsonName = "JoyPacJSON/" + "StringKey_" + ENVIRONMEN; + public string JsonPath = Application.dataPath + "/Resources/" + JsonName + ".json"; +#elif UNITY_EDITOR + public string JsonPath = Application.streamingAssetsPath + "/" + path; //获取文件路径 + +#endif + + + + public Dictionary StringKeyDic = new Dictionary(); + + public Dictionary BuildSettingKey = new Dictionary(); + + + + public void AddStringKeyDic(string key, string value, Dictionary dic) + { + + dic.Add(key, value); + + } + + /// + /// 字典转json并写入json文件 + /// 写入json文件 + /// + public void SerializeDictionaryToJsonString(Dictionary dic, string jsonPath) + { + if (dic.Count == 0) + return; + CreatFile(); + string jsonStr = JsonConvert.SerializeObject(dic); + Debug.Log("JoyPacSDK写入参数: " + jsonStr); + + if (!File.Exists(jsonPath)) // 判断是否已有相同文件 + { + FileStream fs1 = new FileStream(jsonPath, FileMode.Create, FileAccess.ReadWrite); + fs1.Close(); + } + + + File.WriteAllText(jsonPath, ""); + File.WriteAllText(jsonPath, JsonConvert.SerializeObject(jsonStr)); + + + isUndateStringKey = true; + + } + + public void CreatFile() + { + string pathBuild = Application.dataPath + "/JoyPacSDK/BuildString"; + if (!File.Exists(pathBuild)) // 判断是否已有相同文件 + { + Directory.CreateDirectory(pathBuild); + } +#if UNITY_IOS + string path = Application.streamingAssetsPath; + if (!File.Exists(path)) // 判断是否已有相同文件 + { + Directory.CreateDirectory(path); + } + +#elif UNITY_ANDROID + string path = Application.dataPath + "/Resources"; + if (!File.Exists(path)) // 判断是否已有相同文件 + { + Directory.CreateDirectory(path); + } + + string pathJson = path + "/JoyPacJSON"; + if (!File.Exists(pathJson)) // 判断是否已有相同文件 + { + Directory.CreateDirectory(pathJson); + } +#endif + } + + + public void ClearStringKeyDic(Dictionary dic) + { + dic.Clear(); + } + + + public DynamicStringsKey StringsKey() + { + DynamicStringsKey stringsKey = new DynamicStringsKey(); + +#if UNITY_IOS + if (!File.Exists(JsonPath)) + { + Debug.LogError(JsonPath + "---------不存在此json文件请先生成json文件"); + return stringsKey; + } + + string json = (string)new JsonSerializer().Deserialize(new JsonTextReader(new StringReader((File.ReadAllText(JsonPath))))); + + stringsKey = JsonConvert.DeserializeObject(json); + isUndateStringKey = false; +#elif UNITY_ANDROID + + TextAsset text = Resources.Load(JsonName); + string json = (string)new JsonSerializer().Deserialize(new JsonTextReader(new StringReader((text.text)))); + if (string.IsNullOrEmpty(json)) + { + Debug.LogError(JsonPath + "---------不存在此json文件请先生成json文件"); + return null; + } + + stringsKey = JsonConvert.DeserializeObject(json); + isUndateStringKey = false; + +#endif + return stringsKey; + } + + + IEnumerator LoadResourceCorotine() + { + UnityWebRequest request = UnityWebRequest.Get(JsonPath); + yield return request.SendWebRequest(); + string str = request.downloadHandler.text; + + + } + + public SettingStringsKey SettingKey() + { + SettingStringsKey settingKey = new SettingStringsKey(); + + if (!File.Exists(BuildJsonPath)) + { + Debug.LogError(BuildJsonPath + "---------不存在此json文件请先生成json文件"); + return settingKey; + } + + string json = (string)new JsonSerializer().Deserialize(new JsonTextReader(new StringReader((File.ReadAllText(BuildJsonPath))))); + + settingKey = JsonConvert.DeserializeObject(json); + return settingKey; + } + + + + + +} + +//public static class StaticStringsParamsName +//{ + +//#if UNITY_IOS +// public const string ENVIRONMEN = "iOS"; +//#elif UNITY_ANDROID +// public const string ENVIRONMEN = "Android"; +//#endif + + + +// public const string AdjustDeeplink = ENVIRONMEN + "_AdjustDeeplink"; +// public const string ADJUST_APP_TOKEN = ENVIRONMEN + "_ADJUST_APP_TOKEN"; +// public const string GA_GAMEKEY = ENVIRONMEN + "_GA_gameKey"; +// public const string GA_SECRETKEY = ENVIRONMEN + "_GA_secretKey"; + + + +//} + diff --git a/popcorn/Assets/JoyPacSDK/Core/StringKey/StringKeyManger.cs.meta b/popcorn/Assets/JoyPacSDK/Core/StringKey/StringKeyManger.cs.meta new file mode 100644 index 00000000..50207b94 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Core/StringKey/StringKeyManger.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b6a224a387e7342e09250cd4d73a9fcc +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust.meta new file mode 100644 index 00000000..fa63a4ae --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0037f51f4c224495397681f3bfedb2b8 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust.meta new file mode 100644 index 00000000..797d6923 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2f1c3330329a44b99b7f3b51cb3221d5 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party.meta new file mode 100644 index 00000000..03a9c0b7 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 799dc47c3dc50486d8401272873de3d2 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party/SimpleJSON.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party/SimpleJSON.cs new file mode 100755 index 00000000..0d85e5df --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party/SimpleJSON.cs @@ -0,0 +1,1038 @@ +//#define USE_SharpZipLib +#if !UNITY_WEBPLAYER +#define USE_FileIO +#endif + +/* * * * * + * A simple JSON Parser / builder + * ------------------------------ + * + * It mainly has been written as a simple JSON parser. It can build a JSON string + * from the node-tree, or generate a node tree from any valid JSON string. + * + * If you want to use compression when saving to file / stream / B64 you have to include + * SharpZipLib ( http://www.icsharpcode.net/opensource/sharpziplib/ ) in your project and + * define "USE_SharpZipLib" at the top of the file + * + * Written by Bunny83 + * 2012-06-09 + * + * Features / attributes: + * - provides strongly typed node classes and lists / dictionaries + * - provides easy access to class members / array items / data values + * - the parser ignores data types. Each value is a string. + * - only double quotes (") are used for quoting strings. + * - values and names are not restricted to quoted strings. They simply add up and are trimmed. + * - There are only 3 types: arrays(JSONArray), objects(JSONClass) and values(JSONData) + * - provides "casting" properties to easily convert to / from those types: + * int / float / double / bool + * - provides a common interface for each node so no explicit casting is required. + * - the parser try to avoid errors, but if malformed JSON is parsed the result is undefined + * + * + * 2012-12-17 Update: + * - Added internal JSONLazyCreator class which simplifies the construction of a JSON tree + * Now you can simple reference any item that doesn't exist yet and it will return a JSONLazyCreator + * The class determines the required type by it's further use, creates the type and removes itself. + * - Added binary serialization / deserialization. + * - Added support for BZip2 zipped binary format. Requires the SharpZipLib ( http://www.icsharpcode.net/opensource/sharpziplib/ ) + * The usage of the SharpZipLib library can be disabled by removing or commenting out the USE_SharpZipLib define at the top + * - The serializer uses different types when it comes to store the values. Since my data values + * are all of type string, the serializer will "try" which format fits best. The order is: int, float, double, bool, string. + * It's not the most efficient way but for a moderate amount of data it should work on all platforms. + * + * * * * */ +using System; +using System.Collections; +using System.Collections.Generic; +using System.Linq; + + +namespace com.adjust.sdk +{ + public enum JSONBinaryTag + { + Array = 1, + Class = 2, + Value = 3, + IntValue = 4, + DoubleValue = 5, + BoolValue = 6, + FloatValue = 7, + } + + public class JSONNode + { + #region common interface + public virtual void Add(string aKey, JSONNode aItem){ } + public virtual JSONNode this[int aIndex] { get { return null; } set { } } + public virtual JSONNode this[string aKey] { get { return null; } set { } } + public virtual string Value { get { return ""; } set { } } + public virtual int Count { get { return 0; } } + + public virtual void Add(JSONNode aItem) + { + Add("", aItem); + } + + public virtual JSONNode Remove(string aKey) { return null; } + public virtual JSONNode Remove(int aIndex) { return null; } + public virtual JSONNode Remove(JSONNode aNode) { return aNode; } + + public virtual IEnumerable Childs { get { yield break;} } + public IEnumerable DeepChilds + { + get + { + foreach (var C in Childs) + foreach (var D in C.DeepChilds) + yield return D; + } + } + + public override string ToString() + { + return "JSONNode"; + } + public virtual string ToString(string aPrefix) + { + return "JSONNode"; + } + + #endregion common interface + + #region typecasting properties + public virtual int AsInt + { + get + { + int v = 0; + if (int.TryParse(Value,out v)) + return v; + return 0; + } + set + { + Value = value.ToString(); + } + } + public virtual float AsFloat + { + get + { + float v = 0.0f; + if (float.TryParse(Value,out v)) + return v; + return 0.0f; + } + set + { + Value = value.ToString(); + } + } + public virtual double AsDouble + { + get + { + double v = 0.0; + if (double.TryParse(Value,out v)) + return v; + return 0.0; + } + set + { + Value = value.ToString(); + } + } + public virtual bool AsBool + { + get + { + bool v = false; + if (bool.TryParse(Value,out v)) + return v; + return !string.IsNullOrEmpty(Value); + } + set + { + Value = (value)?"true":"false"; + } + } + public virtual JSONArray AsArray + { + get + { + return this as JSONArray; + } + } + public virtual JSONClass AsObject + { + get + { + return this as JSONClass; + } + } + + + #endregion typecasting properties + + #region operators + public static implicit operator JSONNode(string s) + { + return new JSONData(s); + } + public static implicit operator string(JSONNode d) + { + return (d == null)?null:d.Value; + } + public static bool operator ==(JSONNode a, object b) + { + if (b == null && a is JSONLazyCreator) + return true; + return System.Object.ReferenceEquals(a,b); + } + + public static bool operator !=(JSONNode a, object b) + { + return !(a == b); + } + public override bool Equals (object obj) + { + return System.Object.ReferenceEquals(this, obj); + } + public override int GetHashCode () + { + return base.GetHashCode(); + } + + + #endregion operators + + internal static string Escape(string aText) + { + string result = ""; + foreach(char c in aText) + { + switch(c) + { + case '\\' : result += "\\\\"; break; + case '\"' : result += "\\\""; break; + case '\n' : result += "\\n" ; break; + case '\r' : result += "\\r" ; break; + case '\t' : result += "\\t" ; break; + case '\b' : result += "\\b" ; break; + case '\f' : result += "\\f" ; break; + default : result += c ; break; + } + } + return result; + } + + public static JSONNode Parse(string aJSON) + { + Stack stack = new Stack(); + JSONNode ctx = null; + int i = 0; + string Token = ""; + string TokenName = ""; + bool QuoteMode = false; + while (i < aJSON.Length) + { + switch (aJSON[i]) + { + case '{': + if (QuoteMode) + { + Token += aJSON[i]; + break; + } + stack.Push(new JSONClass()); + if (ctx != null) + { + TokenName = TokenName.Trim(); + if (ctx is JSONArray) + ctx.Add(stack.Peek()); + else if (TokenName != "") + ctx.Add(TokenName,stack.Peek()); + } + TokenName = ""; + Token = ""; + ctx = stack.Peek(); + break; + + case '[': + if (QuoteMode) + { + Token += aJSON[i]; + break; + } + + stack.Push(new JSONArray()); + if (ctx != null) + { + TokenName = TokenName.Trim(); + if (ctx is JSONArray) + ctx.Add(stack.Peek()); + else if (TokenName != "") + ctx.Add(TokenName,stack.Peek()); + } + TokenName = ""; + Token = ""; + ctx = stack.Peek(); + break; + + case '}': + case ']': + if (QuoteMode) + { + Token += aJSON[i]; + break; + } + if (stack.Count == 0) + throw new Exception("JSON Parse: Too many closing brackets"); + + stack.Pop(); + if (Token != "") + { + TokenName = TokenName.Trim(); + if (ctx is JSONArray) + ctx.Add(Token); + else if (TokenName != "") + ctx.Add(TokenName,Token); + } + TokenName = ""; + Token = ""; + if (stack.Count>0) + ctx = stack.Peek(); + break; + + case ':': + if (QuoteMode) + { + Token += aJSON[i]; + break; + } + TokenName = Token; + Token = ""; + break; + + case '"': + QuoteMode ^= true; + break; + + case ',': + if (QuoteMode) + { + Token += aJSON[i]; + break; + } + if (Token != "") + { + if (ctx is JSONArray) + ctx.Add(Token); + else if (TokenName != "") + ctx.Add(TokenName, Token); + } + TokenName = ""; + Token = ""; + break; + + case '\r': + case '\n': + break; + + case ' ': + case '\t': + if (QuoteMode) + Token += aJSON[i]; + break; + + case '\\': + ++i; + if (QuoteMode) + { + char C = aJSON[i]; + switch (C) + { + case 't' : Token += '\t'; break; + case 'r' : Token += '\r'; break; + case 'n' : Token += '\n'; break; + case 'b' : Token += '\b'; break; + case 'f' : Token += '\f'; break; + case 'u': + { + string s = aJSON.Substring(i+1,4); + Token += (char)int.Parse(s, System.Globalization.NumberStyles.AllowHexSpecifier); + i += 4; + break; + } + default : Token += C; break; + } + } + break; + + default: + Token += aJSON[i]; + break; + } + ++i; + } + if (QuoteMode) + { + throw new Exception("JSON Parse: Quotation marks seems to be messed up."); + } + return ctx; + } + + public virtual void Serialize(System.IO.BinaryWriter aWriter) {} + + public void SaveToStream(System.IO.Stream aData) + { + var W = new System.IO.BinaryWriter(aData); + Serialize(W); + } + + #if USE_SharpZipLib + public void SaveToCompressedStream(System.IO.Stream aData) + { + using (var gzipOut = new ICSharpCode.SharpZipLib.BZip2.BZip2OutputStream(aData)) + { + gzipOut.IsStreamOwner = false; + SaveToStream(gzipOut); + gzipOut.Close(); + } + } + + public void SaveToCompressedFile(string aFileName) + { + #if USE_FileIO + System.IO.Directory.CreateDirectory((new System.IO.FileInfo(aFileName)).Directory.FullName); + using(var F = System.IO.File.OpenWrite(aFileName)) + { + SaveToCompressedStream(F); + } + #else + throw new Exception("Can't use File IO stuff in webplayer"); + #endif + } + public string SaveToCompressedBase64() + { + using (var stream = new System.IO.MemoryStream()) + { + SaveToCompressedStream(stream); + stream.Position = 0; + return System.Convert.ToBase64String(stream.ToArray()); + } + } + + #else + public void SaveToCompressedStream(System.IO.Stream aData) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + public void SaveToCompressedFile(string aFileName) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + public string SaveToCompressedBase64() + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + #endif + + public static JSONNode Deserialize(System.IO.BinaryReader aReader) + { + JSONBinaryTag type = (JSONBinaryTag)aReader.ReadByte(); + switch(type) + { + case JSONBinaryTag.Array: + { + int count = aReader.ReadInt32(); + JSONArray tmp = new JSONArray(); + for(int i = 0; i < count; i++) + tmp.Add(Deserialize(aReader)); + return tmp; + } + case JSONBinaryTag.Class: + { + int count = aReader.ReadInt32(); + JSONClass tmp = new JSONClass(); + for(int i = 0; i < count; i++) + { + string key = aReader.ReadString(); + var val = Deserialize(aReader); + tmp.Add(key, val); + } + return tmp; + } + case JSONBinaryTag.Value: + { + return new JSONData(aReader.ReadString()); + } + case JSONBinaryTag.IntValue: + { + return new JSONData(aReader.ReadInt32()); + } + case JSONBinaryTag.DoubleValue: + { + return new JSONData(aReader.ReadDouble()); + } + case JSONBinaryTag.BoolValue: + { + return new JSONData(aReader.ReadBoolean()); + } + case JSONBinaryTag.FloatValue: + { + return new JSONData(aReader.ReadSingle()); + } + + default: + { + throw new Exception("Error deserializing JSON. Unknown tag: " + type); + } + } + } + + #if USE_SharpZipLib + public static JSONNode LoadFromCompressedStream(System.IO.Stream aData) + { + var zin = new ICSharpCode.SharpZipLib.BZip2.BZip2InputStream(aData); + return LoadFromStream(zin); + } + public static JSONNode LoadFromCompressedFile(string aFileName) + { + #if USE_FileIO + using(var F = System.IO.File.OpenRead(aFileName)) + { + return LoadFromCompressedStream(F); + } + #else + throw new Exception("Can't use File IO stuff in webplayer"); + #endif + } + public static JSONNode LoadFromCompressedBase64(string aBase64) + { + var tmp = System.Convert.FromBase64String(aBase64); + var stream = new System.IO.MemoryStream(tmp); + stream.Position = 0; + return LoadFromCompressedStream(stream); + } + #else + public static JSONNode LoadFromCompressedFile(string aFileName) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + public static JSONNode LoadFromCompressedStream(System.IO.Stream aData) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + public static JSONNode LoadFromCompressedBase64(string aBase64) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + #endif + + public static JSONNode LoadFromStream(System.IO.Stream aData) + { + using(var R = new System.IO.BinaryReader(aData)) + { + return Deserialize(R); + } + } + public static JSONNode LoadFromBase64(string aBase64) + { + var tmp = System.Convert.FromBase64String(aBase64); + var stream = new System.IO.MemoryStream(tmp); + stream.Position = 0; + return LoadFromStream(stream); + } + } // End of JSONNode + + public class JSONArray : JSONNode, IEnumerable + { + private List m_List = new List(); + public override JSONNode this[int aIndex] + { + get + { + if (aIndex<0 || aIndex >= m_List.Count) + return new JSONLazyCreator(this); + return m_List[aIndex]; + } + set + { + if (aIndex<0 || aIndex >= m_List.Count) + m_List.Add(value); + else + m_List[aIndex] = value; + } + } + public override JSONNode this[string aKey] + { + get{ return new JSONLazyCreator(this);} + set{ m_List.Add(value); } + } + public override int Count + { + get { return m_List.Count; } + } + public override void Add(string aKey, JSONNode aItem) + { + m_List.Add(aItem); + } + public override JSONNode Remove(int aIndex) + { + if (aIndex < 0 || aIndex >= m_List.Count) + return null; + JSONNode tmp = m_List[aIndex]; + m_List.RemoveAt(aIndex); + return tmp; + } + public override JSONNode Remove(JSONNode aNode) + { + m_List.Remove(aNode); + return aNode; + } + public override IEnumerable Childs + { + get + { + foreach(JSONNode N in m_List) + yield return N; + } + } + public IEnumerator GetEnumerator() + { + foreach(JSONNode N in m_List) + yield return N; + } + public override string ToString() + { + string result = "[ "; + foreach (JSONNode N in m_List) + { + if (result.Length > 2) + result += ", "; + result += N.ToString(); + } + result += " ]"; + return result; + } + public override string ToString(string aPrefix) + { + string result = "[ "; + foreach (JSONNode N in m_List) + { + if (result.Length > 3) + result += ", "; + result += "\n" + aPrefix + " "; + result += N.ToString(aPrefix+" "); + } + result += "\n" + aPrefix + "]"; + return result; + } + public override void Serialize (System.IO.BinaryWriter aWriter) + { + aWriter.Write((byte)JSONBinaryTag.Array); + aWriter.Write(m_List.Count); + for(int i = 0; i < m_List.Count; i++) + { + m_List[i].Serialize(aWriter); + } + } + } // End of JSONArray + + public class JSONClass : JSONNode, IEnumerable + { + private Dictionary m_Dict = new Dictionary(); + public override JSONNode this[string aKey] + { + get + { + if (m_Dict.ContainsKey(aKey)) + return m_Dict[aKey]; + else + return new JSONLazyCreator(this, aKey); + } + set + { + if (m_Dict.ContainsKey(aKey)) + m_Dict[aKey] = value; + else + m_Dict.Add(aKey,value); + } + } + public override JSONNode this[int aIndex] + { + get + { + if (aIndex < 0 || aIndex >= m_Dict.Count) + return null; + return m_Dict.ElementAt(aIndex).Value; + } + set + { + if (aIndex < 0 || aIndex >= m_Dict.Count) + return; + string key = m_Dict.ElementAt(aIndex).Key; + m_Dict[key] = value; + } + } + public override int Count + { + get { return m_Dict.Count; } + } + + + public override void Add(string aKey, JSONNode aItem) + { + if (!string.IsNullOrEmpty(aKey)) + { + if (m_Dict.ContainsKey(aKey)) + m_Dict[aKey] = aItem; + else + m_Dict.Add(aKey, aItem); + } + else + m_Dict.Add(Guid.NewGuid().ToString(), aItem); + } + + public override JSONNode Remove(string aKey) + { + if (!m_Dict.ContainsKey(aKey)) + return null; + JSONNode tmp = m_Dict[aKey]; + m_Dict.Remove(aKey); + return tmp; + } + public override JSONNode Remove(int aIndex) + { + if (aIndex < 0 || aIndex >= m_Dict.Count) + return null; + var item = m_Dict.ElementAt(aIndex); + m_Dict.Remove(item.Key); + return item.Value; + } + public override JSONNode Remove(JSONNode aNode) + { + try + { + var item = m_Dict.Where(k => k.Value == aNode).First(); + m_Dict.Remove(item.Key); + return aNode; + } + catch + { + return null; + } + } + + public override IEnumerable Childs + { + get + { + foreach(KeyValuePair N in m_Dict) + yield return N.Value; + } + } + + public IEnumerator GetEnumerator() + { + foreach(KeyValuePair N in m_Dict) + yield return N; + } + public override string ToString() + { + string result = "{"; + foreach (KeyValuePair N in m_Dict) + { + if (result.Length > 2) + result += ", "; + result += "\"" + Escape(N.Key) + "\":" + N.Value.ToString(); + } + result += "}"; + return result; + } + public override string ToString(string aPrefix) + { + string result = "{ "; + foreach (KeyValuePair N in m_Dict) + { + if (result.Length > 3) + result += ", "; + result += "\n" + aPrefix + " "; + result += "\"" + Escape(N.Key) + "\" : " + N.Value.ToString(aPrefix+" "); + } + result += "\n" + aPrefix + "}"; + return result; + } + public override void Serialize (System.IO.BinaryWriter aWriter) + { + aWriter.Write((byte)JSONBinaryTag.Class); + aWriter.Write(m_Dict.Count); + foreach(string K in m_Dict.Keys) + { + aWriter.Write(K); + m_Dict[K].Serialize(aWriter); + } + } + } // End of JSONClass + + public class JSONData : JSONNode + { + private string m_Data; + public override string Value + { + get { return m_Data; } + set { m_Data = value; } + } + public JSONData(string aData) + { + m_Data = aData; + } + public JSONData(float aData) + { + AsFloat = aData; + } + public JSONData(double aData) + { + AsDouble = aData; + } + public JSONData(bool aData) + { + AsBool = aData; + } + public JSONData(int aData) + { + AsInt = aData; + } + + public override string ToString() + { + return "\"" + Escape(m_Data) + "\""; + } + public override string ToString(string aPrefix) + { + return "\"" + Escape(m_Data) + "\""; + } + public override void Serialize (System.IO.BinaryWriter aWriter) + { + var tmp = new JSONData(""); + + tmp.AsInt = AsInt; + if (tmp.m_Data == this.m_Data) + { + aWriter.Write((byte)JSONBinaryTag.IntValue); + aWriter.Write(AsInt); + return; + } + tmp.AsFloat = AsFloat; + if (tmp.m_Data == this.m_Data) + { + aWriter.Write((byte)JSONBinaryTag.FloatValue); + aWriter.Write(AsFloat); + return; + } + tmp.AsDouble = AsDouble; + if (tmp.m_Data == this.m_Data) + { + aWriter.Write((byte)JSONBinaryTag.DoubleValue); + aWriter.Write(AsDouble); + return; + } + + tmp.AsBool = AsBool; + if (tmp.m_Data == this.m_Data) + { + aWriter.Write((byte)JSONBinaryTag.BoolValue); + aWriter.Write(AsBool); + return; + } + aWriter.Write((byte)JSONBinaryTag.Value); + aWriter.Write(m_Data); + } + } // End of JSONData + + internal class JSONLazyCreator : JSONNode + { + private JSONNode m_Node = null; + private string m_Key = null; + + public JSONLazyCreator(JSONNode aNode) + { + m_Node = aNode; + m_Key = null; + } + public JSONLazyCreator(JSONNode aNode, string aKey) + { + m_Node = aNode; + m_Key = aKey; + } + + private void Set(JSONNode aVal) + { + if (m_Key == null) + { + m_Node.Add(aVal); + } + else + { + m_Node.Add(m_Key, aVal); + } + m_Node = null; // Be GC friendly. + } + + public override JSONNode this[int aIndex] + { + get + { + return new JSONLazyCreator(this); + } + set + { + var tmp = new JSONArray(); + tmp.Add(value); + Set(tmp); + } + } + + public override JSONNode this[string aKey] + { + get + { + return new JSONLazyCreator(this, aKey); + } + set + { + var tmp = new JSONClass(); + tmp.Add(aKey, value); + Set(tmp); + } + } + public override void Add (JSONNode aItem) + { + var tmp = new JSONArray(); + tmp.Add(aItem); + Set(tmp); + } + public override void Add (string aKey, JSONNode aItem) + { + var tmp = new JSONClass(); + tmp.Add(aKey, aItem); + Set(tmp); + } + public static bool operator ==(JSONLazyCreator a, object b) + { + if (b == null) + return true; + return System.Object.ReferenceEquals(a,b); + } + + public static bool operator !=(JSONLazyCreator a, object b) + { + return !(a == b); + } + public override bool Equals (object obj) + { + if (obj == null) + return true; + return System.Object.ReferenceEquals(this, obj); + } + public override int GetHashCode () + { + return base.GetHashCode(); + } + + public override string ToString() + { + return ""; + } + public override string ToString(string aPrefix) + { + return ""; + } + + public override int AsInt + { + get + { + JSONData tmp = new JSONData(0); + Set(tmp); + return 0; + } + set + { + JSONData tmp = new JSONData(value); + Set(tmp); + } + } + public override float AsFloat + { + get + { + JSONData tmp = new JSONData(0.0f); + Set(tmp); + return 0.0f; + } + set + { + JSONData tmp = new JSONData(value); + Set(tmp); + } + } + public override double AsDouble + { + get + { + JSONData tmp = new JSONData(0.0); + Set(tmp); + return 0.0; + } + set + { + JSONData tmp = new JSONData(value); + Set(tmp); + } + } + public override bool AsBool + { + get + { + JSONData tmp = new JSONData(false); + Set(tmp); + return false; + } + set + { + JSONData tmp = new JSONData(value); + Set(tmp); + } + } + public override JSONArray AsArray + { + get + { + JSONArray tmp = new JSONArray(); + Set(tmp); + return tmp; + } + } + public override JSONClass AsObject + { + get + { + JSONClass tmp = new JSONClass(); + Set(tmp); + return tmp; + } + } + } // End of JSONLazyCreator + + public static class JSON + { + public static JSONNode Parse(string aJSON) + { + return JSONNode.Parse(aJSON); + } + } +} \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party/SimpleJSON.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party/SimpleJSON.cs.meta new file mode 100755 index 00000000..a28238d2 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/3rd Party/SimpleJSON.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9c780c17852614618be5ffd9cc43a75f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android.meta new file mode 100644 index 00000000..bd9b10a8 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f699841cfc175432ebbcd452789c3944 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroid.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroid.cs new file mode 100644 index 00000000..5ace352b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroid.cs @@ -0,0 +1,856 @@ +using System; +using System.Collections.Generic; +using System.Runtime.InteropServices; +using UnityEngine; + +namespace com.adjust.sdk +{ +#if UNITY_ANDROID + public class AdjustAndroid + { + private const string sdkPrefix = "unity4.28.0"; + private static bool launchDeferredDeeplink = true; + private static AndroidJavaClass ajcAdjust = new AndroidJavaClass("com.adjust.sdk.Adjust"); + private static AndroidJavaObject ajoCurrentActivity = new AndroidJavaClass("com.unity3d.player.UnityPlayer").GetStatic("currentActivity"); + private static DeferredDeeplinkListener onDeferredDeeplinkListener; + private static AttributionChangeListener onAttributionChangedListener; + private static EventTrackingFailedListener onEventTrackingFailedListener; + private static EventTrackingSucceededListener onEventTrackingSucceededListener; + private static SessionTrackingFailedListener onSessionTrackingFailedListener; + private static SessionTrackingSucceededListener onSessionTrackingSucceededListener; + + public static void Start(AdjustConfig adjustConfig) + { + // Thank you, Unity 2019.2.0, for breaking this. + // AndroidJavaObject ajoEnvironment = adjustConfig.environment == AdjustEnvironment.Sandbox ? + // new AndroidJavaClass("com.adjust.sdk.AdjustConfig").GetStatic("ENVIRONMENT_SANDBOX") : + // new AndroidJavaClass("com.adjust.sdk.AdjustConfig").GetStatic("ENVIRONMENT_PRODUCTION"); + + // Get environment variable. + string ajoEnvironment = adjustConfig.environment == AdjustEnvironment.Production ? "production" : "sandbox"; + + // Create adjust config object. + AndroidJavaObject ajoAdjustConfig; + + // Check if suppress log leve is supported. + if (adjustConfig.allowSuppressLogLevel != null) + { + ajoAdjustConfig = new AndroidJavaObject("com.adjust.sdk.AdjustConfig", ajoCurrentActivity, adjustConfig.appToken, ajoEnvironment, adjustConfig.allowSuppressLogLevel); + } + else + { + ajoAdjustConfig = new AndroidJavaObject("com.adjust.sdk.AdjustConfig", ajoCurrentActivity, adjustConfig.appToken, ajoEnvironment); + } + + // Check if deferred deeplink should be launched by SDK. + launchDeferredDeeplink = adjustConfig.launchDeferredDeeplink; + + // Check log level. + if (adjustConfig.logLevel != null) + { + AndroidJavaObject ajoLogLevel; + if (adjustConfig.logLevel.Value.ToUppercaseString().Equals("SUPPRESS")) + { + ajoLogLevel = new AndroidJavaClass("com.adjust.sdk.LogLevel").GetStatic("SUPRESS"); + } + else + { + ajoLogLevel = new AndroidJavaClass("com.adjust.sdk.LogLevel").GetStatic(adjustConfig.logLevel.Value.ToUppercaseString()); + } + + if (ajoLogLevel != null) + { + ajoAdjustConfig.Call("setLogLevel", ajoLogLevel); + } + } + + // Set unity SDK prefix. + ajoAdjustConfig.Call("setSdkPrefix", sdkPrefix); + + // Check if user has configured the delayed start option. + if (adjustConfig.delayStart != null) + { + ajoAdjustConfig.Call("setDelayStart", adjustConfig.delayStart); + } + + // Check event buffering setting. + if (adjustConfig.eventBufferingEnabled != null) + { + AndroidJavaObject ajoIsEnabled = new AndroidJavaObject("java.lang.Boolean", adjustConfig.eventBufferingEnabled.Value); + ajoAdjustConfig.Call("setEventBufferingEnabled", ajoIsEnabled); + } + + // Check if user enabled tracking in the background. + if (adjustConfig.sendInBackground != null) + { + ajoAdjustConfig.Call("setSendInBackground", adjustConfig.sendInBackground.Value); + } + + // Check if user wants to get cost data in attribution callback. + if (adjustConfig.needsCost != null) + { + ajoAdjustConfig.Call("setNeedsCost", adjustConfig.needsCost.Value); + } + + // Check if user wants to run preinstall campaigns. + if (adjustConfig.preinstallTrackingEnabled != null) + { + ajoAdjustConfig.Call("setPreinstallTrackingEnabled", adjustConfig.preinstallTrackingEnabled.Value); + } + + // Check if user has set user agent value. + if (adjustConfig.userAgent != null) + { + ajoAdjustConfig.Call("setUserAgent", adjustConfig.userAgent); + } + + // Check if user has set default process name. + if (!String.IsNullOrEmpty(adjustConfig.processName)) + { + ajoAdjustConfig.Call("setProcessName", adjustConfig.processName); + } + + // Check if user has set default tracker token. + if (adjustConfig.defaultTracker != null) + { + ajoAdjustConfig.Call("setDefaultTracker", adjustConfig.defaultTracker); + } + + // Check if user has set external device identifier. + if (adjustConfig.externalDeviceId != null) + { + ajoAdjustConfig.Call("setExternalDeviceId", adjustConfig.externalDeviceId); + } + + // Check if user has set custom URL strategy. + if (adjustConfig.urlStrategy != null) + { + if (adjustConfig.urlStrategy == AdjustConfig.AdjustUrlStrategyChina) + { + AndroidJavaObject ajoUrlStrategyChina = new AndroidJavaClass("com.adjust.sdk.AdjustConfig").GetStatic("URL_STRATEGY_CHINA"); + ajoAdjustConfig.Call("setUrlStrategy", ajoUrlStrategyChina); + } + else if (adjustConfig.urlStrategy == AdjustConfig.AdjustUrlStrategyIndia) + { + AndroidJavaObject ajoUrlStrategyIndia = new AndroidJavaClass("com.adjust.sdk.AdjustConfig").GetStatic("URL_STRATEGY_INDIA"); + ajoAdjustConfig.Call("setUrlStrategy", ajoUrlStrategyIndia); + } + else if (adjustConfig.urlStrategy == AdjustConfig.AdjustDataResidencyEU) + { + AndroidJavaObject ajoDataResidencyEU = new AndroidJavaClass("com.adjust.sdk.AdjustConfig").GetStatic("DATA_RESIDENCY_EU"); + ajoAdjustConfig.Call("setUrlStrategy", ajoDataResidencyEU); + } + } + + // Check if user has set app secret. + if (IsAppSecretSet(adjustConfig)) + { + ajoAdjustConfig.Call("setAppSecret", + adjustConfig.secretId.Value, + adjustConfig.info1.Value, + adjustConfig.info2.Value, + adjustConfig.info3.Value, + adjustConfig.info4.Value); + } + + // Check if user has set device as known. + if (adjustConfig.isDeviceKnown.HasValue) + { + ajoAdjustConfig.Call("setDeviceKnown", adjustConfig.isDeviceKnown.Value); + } + + // Check if user has enabled reading of IMEI and MEID. + // Obsolete method. + if (adjustConfig.readImei.HasValue) + { + // ajoAdjustConfig.Call("setReadMobileEquipmentIdentity", adjustConfig.readImei.Value); + } + + // Check attribution changed delagate setting. + if (adjustConfig.attributionChangedDelegate != null) + { + onAttributionChangedListener = new AttributionChangeListener(adjustConfig.attributionChangedDelegate); + ajoAdjustConfig.Call("setOnAttributionChangedListener", onAttributionChangedListener); + } + + // Check event success delegate setting. + if (adjustConfig.eventSuccessDelegate != null) + { + onEventTrackingSucceededListener = new EventTrackingSucceededListener(adjustConfig.eventSuccessDelegate); + ajoAdjustConfig.Call("setOnEventTrackingSucceededListener", onEventTrackingSucceededListener); + } + + // Check event failure delagate setting. + if (adjustConfig.eventFailureDelegate != null) + { + onEventTrackingFailedListener = new EventTrackingFailedListener(adjustConfig.eventFailureDelegate); + ajoAdjustConfig.Call("setOnEventTrackingFailedListener", onEventTrackingFailedListener); + } + + // Check session success delegate setting. + if (adjustConfig.sessionSuccessDelegate != null) + { + onSessionTrackingSucceededListener = new SessionTrackingSucceededListener(adjustConfig.sessionSuccessDelegate); + ajoAdjustConfig.Call("setOnSessionTrackingSucceededListener", onSessionTrackingSucceededListener); + } + + // Check session failure delegate setting. + if (adjustConfig.sessionFailureDelegate != null) + { + onSessionTrackingFailedListener = new SessionTrackingFailedListener(adjustConfig.sessionFailureDelegate); + ajoAdjustConfig.Call("setOnSessionTrackingFailedListener", onSessionTrackingFailedListener); + } + + // Check deferred deeplink delegate setting. + if (adjustConfig.deferredDeeplinkDelegate != null) + { + onDeferredDeeplinkListener = new DeferredDeeplinkListener(adjustConfig.deferredDeeplinkDelegate); + ajoAdjustConfig.Call("setOnDeeplinkResponseListener", onDeferredDeeplinkListener); + } + + // Initialise and start the SDK. + ajcAdjust.CallStatic("onCreate", ajoAdjustConfig); + ajcAdjust.CallStatic("onResume"); + } + + public static void TrackEvent(AdjustEvent adjustEvent) + { + AndroidJavaObject ajoAdjustEvent = new AndroidJavaObject("com.adjust.sdk.AdjustEvent", adjustEvent.eventToken); + + // Check if user has set revenue for the event. + if (adjustEvent.revenue != null) + { + ajoAdjustEvent.Call("setRevenue", (double)adjustEvent.revenue, adjustEvent.currency); + } + + // Check if user has added any callback parameters to the event. + if (adjustEvent.callbackList != null) + { + for (int i = 0; i < adjustEvent.callbackList.Count; i += 2) + { + string key = adjustEvent.callbackList[i]; + string value = adjustEvent.callbackList[i + 1]; + ajoAdjustEvent.Call("addCallbackParameter", key, value); + } + } + + // Check if user has added any partner parameters to the event. + if (adjustEvent.partnerList != null) + { + for (int i = 0; i < adjustEvent.partnerList.Count; i += 2) + { + string key = adjustEvent.partnerList[i]; + string value = adjustEvent.partnerList[i + 1]; + ajoAdjustEvent.Call("addPartnerParameter", key, value); + } + } + + // Check if user has added transaction ID to the event. + if (adjustEvent.transactionId != null) + { + ajoAdjustEvent.Call("setOrderId", adjustEvent.transactionId); + } + + // Check if user has added callback ID to the event. + if (adjustEvent.callbackId != null) + { + ajoAdjustEvent.Call("setCallbackId", adjustEvent.callbackId); + } + + // Track the event. + ajcAdjust.CallStatic("trackEvent", ajoAdjustEvent); + } + + public static bool IsEnabled() + { + return ajcAdjust.CallStatic("isEnabled"); + } + + public static void SetEnabled(bool enabled) + { + ajcAdjust.CallStatic("setEnabled", enabled); + } + + public static void SetOfflineMode(bool enabled) + { + ajcAdjust.CallStatic("setOfflineMode", enabled); + } + + public static void SendFirstPackages() + { + ajcAdjust.CallStatic("sendFirstPackages"); + } + + public static void SetDeviceToken(string deviceToken) + { + ajcAdjust.CallStatic("setPushToken", deviceToken, ajoCurrentActivity); + } + + public static string GetAdid() + { + return ajcAdjust.CallStatic("getAdid"); + } + + public static void GdprForgetMe() + { + ajcAdjust.CallStatic("gdprForgetMe", ajoCurrentActivity); + } + + public static void DisableThirdPartySharing() + { + ajcAdjust.CallStatic("disableThirdPartySharing", ajoCurrentActivity); + } + + public static AdjustAttribution GetAttribution() + { + try + { + AndroidJavaObject ajoAttribution = ajcAdjust.CallStatic("getAttribution"); + if (null == ajoAttribution) + { + return null; + } + + AdjustAttribution adjustAttribution = new AdjustAttribution(); + adjustAttribution.trackerName = ajoAttribution.Get(AdjustUtils.KeyTrackerName) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyTrackerName); + adjustAttribution.trackerToken = ajoAttribution.Get(AdjustUtils.KeyTrackerToken) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyTrackerToken); + adjustAttribution.network = ajoAttribution.Get(AdjustUtils.KeyNetwork) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyNetwork); + adjustAttribution.campaign = ajoAttribution.Get(AdjustUtils.KeyCampaign) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyCampaign); + adjustAttribution.adgroup = ajoAttribution.Get(AdjustUtils.KeyAdgroup) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyAdgroup); + adjustAttribution.creative = ajoAttribution.Get(AdjustUtils.KeyCreative) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyCreative); + adjustAttribution.clickLabel = ajoAttribution.Get(AdjustUtils.KeyClickLabel) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyClickLabel); + adjustAttribution.adid = ajoAttribution.Get(AdjustUtils.KeyAdid) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyAdid); + adjustAttribution.costType = ajoAttribution.Get(AdjustUtils.KeyCostType) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyCostType); + AndroidJavaObject ajoCostAmount = ajoAttribution.Get(AdjustUtils.KeyCostAmount) == null ? + null : ajoAttribution.Get(AdjustUtils.KeyCostAmount); + if (ajoCostAmount == null) + { + adjustAttribution.costAmount = null; + } + else + { + double costAmount = ajoCostAmount.Call("doubleValue"); + adjustAttribution.costAmount = costAmount; + } + adjustAttribution.costCurrency = ajoAttribution.Get(AdjustUtils.KeyCostCurrency) == "" ? + null : ajoAttribution.Get(AdjustUtils.KeyCostCurrency); + return adjustAttribution; + } + catch (Exception) {} + + return null; + } + + public static void AddSessionPartnerParameter(string key, string value) + { + if (ajcAdjust == null) + { + ajcAdjust = new AndroidJavaClass("com.adjust.sdk.Adjust"); + } + ajcAdjust.CallStatic("addSessionPartnerParameter", key, value); + } + + public static void AddSessionCallbackParameter(string key, string value) + { + if (ajcAdjust == null) + { + ajcAdjust = new AndroidJavaClass("com.adjust.sdk.Adjust"); + } + ajcAdjust.CallStatic("addSessionCallbackParameter", key, value); + } + + public static void RemoveSessionPartnerParameter(string key) + { + if (ajcAdjust == null) + { + ajcAdjust = new AndroidJavaClass("com.adjust.sdk.Adjust"); + } + ajcAdjust.CallStatic("removeSessionPartnerParameter", key); + } + + public static void RemoveSessionCallbackParameter(string key) + { + if (ajcAdjust == null) + { + ajcAdjust = new AndroidJavaClass("com.adjust.sdk.Adjust"); + } + ajcAdjust.CallStatic("removeSessionCallbackParameter", key); + } + + public static void ResetSessionPartnerParameters() + { + if (ajcAdjust == null) + { + ajcAdjust = new AndroidJavaClass("com.adjust.sdk.Adjust"); + } + ajcAdjust.CallStatic("resetSessionPartnerParameters"); + } + + public static void ResetSessionCallbackParameters() + { + if (ajcAdjust == null) + { + ajcAdjust = new AndroidJavaClass("com.adjust.sdk.Adjust"); + } + ajcAdjust.CallStatic("resetSessionCallbackParameters"); + } + + public static void AppWillOpenUrl(string url) + { + AndroidJavaClass ajcUri = new AndroidJavaClass("android.net.Uri"); + AndroidJavaObject ajoUri = ajcUri.CallStatic("parse", url); + ajcAdjust.CallStatic("appWillOpenUrl", ajoUri, ajoCurrentActivity); + } + + public static void TrackAdRevenue(string source, string payload) + { + if (ajcAdjust == null) + { + ajcAdjust = new AndroidJavaClass("com.adjust.sdk.Adjust"); + } + AndroidJavaObject jsonPayload = new AndroidJavaObject("org.json.JSONObject", payload); + ajcAdjust.CallStatic("trackAdRevenue", source, jsonPayload); + } + + public static void TrackPlayStoreSubscription(AdjustPlayStoreSubscription subscription) + { + AndroidJavaObject ajoSubscription = new AndroidJavaObject("com.adjust.sdk.AdjustPlayStoreSubscription", + Convert.ToInt64(subscription.price), + subscription.currency, + subscription.sku, + subscription.orderId, + subscription.signature, + subscription.purchaseToken); + + // Check if user has set purchase time for subscription. + if (subscription.purchaseTime != null) + { + ajoSubscription.Call("setPurchaseTime", Convert.ToInt64(subscription.purchaseTime)); + } + + // Check if user has added any callback parameters to the subscription. + if (subscription.callbackList != null) + { + for (int i = 0; i < subscription.callbackList.Count; i += 2) + { + string key = subscription.callbackList[i]; + string value = subscription.callbackList[i + 1]; + ajoSubscription.Call("addCallbackParameter", key, value); + } + } + + // Check if user has added any partner parameters to the subscription. + if (subscription.partnerList != null) + { + for (int i = 0; i < subscription.partnerList.Count; i += 2) + { + string key = subscription.partnerList[i]; + string value = subscription.partnerList[i + 1]; + ajoSubscription.Call("addPartnerParameter", key, value); + } + } + + // Track the subscription. + ajcAdjust.CallStatic("trackPlayStoreSubscription", ajoSubscription); + } + + public static void TrackThirdPartySharing(AdjustThirdPartySharing thirdPartySharing) + { + AndroidJavaObject ajoIsEnabled; + AndroidJavaObject ajoAdjustThirdPartySharing; + if (thirdPartySharing.isEnabled != null) + { + ajoIsEnabled = new AndroidJavaObject("java.lang.Boolean", thirdPartySharing.isEnabled.Value); + ajoAdjustThirdPartySharing = new AndroidJavaObject("com.adjust.sdk.AdjustThirdPartySharing", ajoIsEnabled); + } + else + { + string[] parameters = null; + ajoAdjustThirdPartySharing = new AndroidJavaObject("com.adjust.sdk.AdjustThirdPartySharing", parameters); + } + + if (thirdPartySharing.granularOptions != null) + { + foreach (KeyValuePair> entry in thirdPartySharing.granularOptions) + { + for (int i = 0; i < entry.Value.Count;) + { + ajoAdjustThirdPartySharing.Call("addGranularOption", entry.Key, entry.Value[i++], entry.Value[i++]); + } + } + } + + ajcAdjust.CallStatic("trackThirdPartySharing", ajoAdjustThirdPartySharing); + } + + public static void TrackMeasurementConsent(bool measurementConsent) + { + ajcAdjust.CallStatic("trackMeasurementConsent", measurementConsent); + } + + // Android specific methods. + public static void OnPause() + { + ajcAdjust.CallStatic("onPause"); + } + + public static void OnResume() + { + ajcAdjust.CallStatic("onResume"); + } + + public static void SetReferrer(string referrer) + { + ajcAdjust.CallStatic("setReferrer", referrer, ajoCurrentActivity); + } + + public static void GetGoogleAdId(Action onDeviceIdsRead) + { + DeviceIdsReadListener onDeviceIdsReadProxy = new DeviceIdsReadListener(onDeviceIdsRead); + ajcAdjust.CallStatic("getGoogleAdId", ajoCurrentActivity, onDeviceIdsReadProxy); + } + + public static string GetAmazonAdId() + { + return ajcAdjust.CallStatic("getAmazonAdId", ajoCurrentActivity); + } + + public static string GetSdkVersion() + { + string nativeSdkVersion = ajcAdjust.CallStatic("getSdkVersion"); + return sdkPrefix + "@" + nativeSdkVersion; + } + + // Used for testing only. + public static void SetTestOptions(Dictionary testOptions) + { + AndroidJavaObject ajoTestOptions = AdjustUtils.TestOptionsMap2AndroidJavaObject(testOptions, ajoCurrentActivity); + ajcAdjust.CallStatic("setTestOptions", ajoTestOptions); + } + + // Private & helper classes. + private class AttributionChangeListener : AndroidJavaProxy + { + private Action callback; + + public AttributionChangeListener(Action pCallback) : base("com.adjust.sdk.OnAttributionChangedListener") + { + this.callback = pCallback; + } + + // Method must be lowercase to match Android method signature. + public void onAttributionChanged(AndroidJavaObject attribution) + { + if (callback == null) + { + return; + } + + AdjustAttribution adjustAttribution = new AdjustAttribution(); + adjustAttribution.trackerName = attribution.Get(AdjustUtils.KeyTrackerName) == "" ? + null : attribution.Get(AdjustUtils.KeyTrackerName); + adjustAttribution.trackerToken = attribution.Get(AdjustUtils.KeyTrackerToken) == "" ? + null : attribution.Get(AdjustUtils.KeyTrackerToken); + adjustAttribution.network = attribution.Get(AdjustUtils.KeyNetwork) == "" ? + null : attribution.Get(AdjustUtils.KeyNetwork); + adjustAttribution.campaign = attribution.Get(AdjustUtils.KeyCampaign) == "" ? + null : attribution.Get(AdjustUtils.KeyCampaign); + adjustAttribution.adgroup = attribution.Get(AdjustUtils.KeyAdgroup) == "" ? + null : attribution.Get(AdjustUtils.KeyAdgroup); + adjustAttribution.creative = attribution.Get(AdjustUtils.KeyCreative) == "" ? + null : attribution.Get(AdjustUtils.KeyCreative); + adjustAttribution.clickLabel = attribution.Get(AdjustUtils.KeyClickLabel) == "" ? + null : attribution.Get(AdjustUtils.KeyClickLabel); + adjustAttribution.adid = attribution.Get(AdjustUtils.KeyAdid) == "" ? + null : attribution.Get(AdjustUtils.KeyAdid); + adjustAttribution.costType = attribution.Get(AdjustUtils.KeyCostType) == "" ? + null : attribution.Get(AdjustUtils.KeyCostType); + AndroidJavaObject ajoCostAmount = attribution.Get(AdjustUtils.KeyCostAmount) == null ? + null : attribution.Get(AdjustUtils.KeyCostAmount); + if (ajoCostAmount == null) + { + adjustAttribution.costAmount = null; + } + else + { + double costAmount = ajoCostAmount.Call("doubleValue"); + adjustAttribution.costAmount = costAmount; + } + adjustAttribution.costCurrency = attribution.Get(AdjustUtils.KeyCostCurrency) == "" ? + null : attribution.Get(AdjustUtils.KeyCostCurrency); + callback(adjustAttribution); + } + } + + private class DeferredDeeplinkListener : AndroidJavaProxy + { + private Action callback; + + public DeferredDeeplinkListener(Action pCallback) : base("com.adjust.sdk.OnDeeplinkResponseListener") + { + this.callback = pCallback; + } + + // Method must be lowercase to match Android method signature. + public bool launchReceivedDeeplink(AndroidJavaObject deeplink) + { + if (callback == null) + { + return launchDeferredDeeplink; + } + + string deeplinkURL = deeplink.Call("toString"); + callback(deeplinkURL); + return launchDeferredDeeplink; + } + } + + private class EventTrackingSucceededListener : AndroidJavaProxy + { + private Action callback; + + public EventTrackingSucceededListener(Action pCallback) : base("com.adjust.sdk.OnEventTrackingSucceededListener") + { + this.callback = pCallback; + } + + // Method must be lowercase to match Android method signature. + public void onFinishedEventTrackingSucceeded(AndroidJavaObject eventSuccessData) + { + if (callback == null) + { + return; + } + if (eventSuccessData == null) + { + return; + } + + AdjustEventSuccess adjustEventSuccess = new AdjustEventSuccess(); + adjustEventSuccess.Adid = eventSuccessData.Get(AdjustUtils.KeyAdid) == "" ? + null : eventSuccessData.Get(AdjustUtils.KeyAdid); + adjustEventSuccess.Message = eventSuccessData.Get(AdjustUtils.KeyMessage) == "" ? + null : eventSuccessData.Get(AdjustUtils.KeyMessage); + adjustEventSuccess.Timestamp = eventSuccessData.Get(AdjustUtils.KeyTimestamp) == "" ? + null : eventSuccessData.Get(AdjustUtils.KeyTimestamp); + adjustEventSuccess.EventToken = eventSuccessData.Get(AdjustUtils.KeyEventToken) == "" ? + null : eventSuccessData.Get(AdjustUtils.KeyEventToken); + adjustEventSuccess.CallbackId = eventSuccessData.Get(AdjustUtils.KeyCallbackId) == "" ? + null : eventSuccessData.Get(AdjustUtils.KeyCallbackId); + + try + { + AndroidJavaObject ajoJsonResponse = eventSuccessData.Get(AdjustUtils.KeyJsonResponse); + string jsonResponseString = ajoJsonResponse.Call("toString"); + adjustEventSuccess.BuildJsonResponseFromString(jsonResponseString); + } + catch (Exception) + { + // JSON response reading failed. + // Native Android SDK should send empty JSON object if none available as of v4.12.5. + // Native Android SDK added special logic to send Unity friendly values as of v4.15.0. + } + + callback(adjustEventSuccess); + } + } + + private class EventTrackingFailedListener : AndroidJavaProxy + { + private Action callback; + + public EventTrackingFailedListener(Action pCallback) : base("com.adjust.sdk.OnEventTrackingFailedListener") + { + this.callback = pCallback; + } + + // Method must be lowercase to match Android method signature. + public void onFinishedEventTrackingFailed(AndroidJavaObject eventFailureData) + { + if (callback == null) + { + return; + } + if (eventFailureData == null) + { + return; + } + + AdjustEventFailure adjustEventFailure = new AdjustEventFailure(); + adjustEventFailure.Adid = eventFailureData.Get(AdjustUtils.KeyAdid) == "" ? + null : eventFailureData.Get(AdjustUtils.KeyAdid); + adjustEventFailure.Message = eventFailureData.Get(AdjustUtils.KeyMessage) == "" ? + null : eventFailureData.Get(AdjustUtils.KeyMessage); + adjustEventFailure.WillRetry = eventFailureData.Get(AdjustUtils.KeyWillRetry); + adjustEventFailure.Timestamp = eventFailureData.Get(AdjustUtils.KeyTimestamp) == "" ? + null : eventFailureData.Get(AdjustUtils.KeyTimestamp); + adjustEventFailure.EventToken = eventFailureData.Get(AdjustUtils.KeyEventToken) == "" ? + null : eventFailureData.Get(AdjustUtils.KeyEventToken); + adjustEventFailure.CallbackId = eventFailureData.Get(AdjustUtils.KeyCallbackId) == "" ? + null : eventFailureData.Get(AdjustUtils.KeyCallbackId); + + try + { + AndroidJavaObject ajoJsonResponse = eventFailureData.Get(AdjustUtils.KeyJsonResponse); + string jsonResponseString = ajoJsonResponse.Call("toString"); + adjustEventFailure.BuildJsonResponseFromString(jsonResponseString); + } + catch (Exception) + { + // JSON response reading failed. + // Native Android SDK should send empty JSON object if none available as of v4.12.5. + // Native Android SDK added special logic to send Unity friendly values as of v4.15.0. + } + + callback(adjustEventFailure); + } + } + + private class SessionTrackingSucceededListener : AndroidJavaProxy + { + private Action callback; + + public SessionTrackingSucceededListener(Action pCallback) : base("com.adjust.sdk.OnSessionTrackingSucceededListener") + { + this.callback = pCallback; + } + + // Method must be lowercase to match Android method signature. + public void onFinishedSessionTrackingSucceeded(AndroidJavaObject sessionSuccessData) + { + if (callback == null) + { + return; + } + if (sessionSuccessData == null) + { + return; + } + + AdjustSessionSuccess adjustSessionSuccess = new AdjustSessionSuccess(); + adjustSessionSuccess.Adid = sessionSuccessData.Get(AdjustUtils.KeyAdid) == "" ? + null : sessionSuccessData.Get(AdjustUtils.KeyAdid); + adjustSessionSuccess.Message = sessionSuccessData.Get(AdjustUtils.KeyMessage) == "" ? + null : sessionSuccessData.Get(AdjustUtils.KeyMessage); + adjustSessionSuccess.Timestamp = sessionSuccessData.Get(AdjustUtils.KeyTimestamp) == "" ? + null : sessionSuccessData.Get(AdjustUtils.KeyTimestamp); + + try + { + AndroidJavaObject ajoJsonResponse = sessionSuccessData.Get(AdjustUtils.KeyJsonResponse); + string jsonResponseString = ajoJsonResponse.Call("toString"); + adjustSessionSuccess.BuildJsonResponseFromString(jsonResponseString); + } + catch (Exception) + { + // JSON response reading failed. + // Native Android SDK should send empty JSON object if none available as of v4.12.5. + // Native Android SDK added special logic to send Unity friendly values as of v4.15.0. + } + + callback(adjustSessionSuccess); + } + } + + private class SessionTrackingFailedListener : AndroidJavaProxy + { + private Action callback; + + public SessionTrackingFailedListener(Action pCallback) : base("com.adjust.sdk.OnSessionTrackingFailedListener") + { + this.callback = pCallback; + } + + // Method must be lowercase to match Android method signature. + public void onFinishedSessionTrackingFailed(AndroidJavaObject sessionFailureData) + { + if (callback == null) + { + return; + } + if (sessionFailureData == null) + { + return; + } + + AdjustSessionFailure adjustSessionFailure = new AdjustSessionFailure(); + adjustSessionFailure.Adid = sessionFailureData.Get(AdjustUtils.KeyAdid) == "" ? + null : sessionFailureData.Get(AdjustUtils.KeyAdid); + adjustSessionFailure.Message = sessionFailureData.Get(AdjustUtils.KeyMessage) == "" ? + null : sessionFailureData.Get(AdjustUtils.KeyMessage); + adjustSessionFailure.WillRetry = sessionFailureData.Get(AdjustUtils.KeyWillRetry); + adjustSessionFailure.Timestamp = sessionFailureData.Get(AdjustUtils.KeyTimestamp) == "" ? + null : sessionFailureData.Get(AdjustUtils.KeyTimestamp); + + try + { + AndroidJavaObject ajoJsonResponse = sessionFailureData.Get(AdjustUtils.KeyJsonResponse); + string jsonResponseString = ajoJsonResponse.Call("toString"); + adjustSessionFailure.BuildJsonResponseFromString(jsonResponseString); + } + catch (Exception) + { + // JSON response reading failed. + // Native Android SDK should send empty JSON object if none available as of v4.12.5. + // Native Android SDK added special logic to send Unity friendly values as of v4.15.0. + } + + callback(adjustSessionFailure); + } + } + + private class DeviceIdsReadListener : AndroidJavaProxy + { + private Action onPlayAdIdReadCallback; + + public DeviceIdsReadListener(Action pCallback) : base("com.adjust.sdk.OnDeviceIdsRead") + { + this.onPlayAdIdReadCallback = pCallback; + } + + // Method must be lowercase to match Android method signature. + public void onGoogleAdIdRead(string playAdId) + { + if (onPlayAdIdReadCallback == null) + { + return; + } + + this.onPlayAdIdReadCallback(playAdId); + } + + // Handling of null object. + public void onGoogleAdIdRead(AndroidJavaObject ajoAdId) + { + if (ajoAdId == null) + { + string adId = null; + this.onGoogleAdIdRead(adId); + return; + } + + this.onGoogleAdIdRead(ajoAdId.Call("toString")); + } + } + + // Private & helper methods. + private static bool IsAppSecretSet(AdjustConfig adjustConfig) + { + return adjustConfig.secretId.HasValue + && adjustConfig.info1.HasValue + && adjustConfig.info2.HasValue + && adjustConfig.info3.HasValue + && adjustConfig.info4.HasValue; + } + } +#endif +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroid.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroid.cs.meta new file mode 100644 index 00000000..f977efdb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroid.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1b21499aaf10a42e8b6377af71a35ba5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroidManifest.xml b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroidManifest.xml new file mode 100755 index 00000000..0d336396 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroidManifest.xml @@ -0,0 +1,49 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroidManifest.xml.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroidManifest.xml.meta new file mode 100755 index 00000000..58af3b49 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroidManifest.xml.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: a13ef442648c346a79f9ff24875c037a +TextScriptImporter: + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/adjust-android.jar b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/adjust-android.jar new file mode 100644 index 00000000..da7430a6 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/adjust-android.jar differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/adjust-android.jar.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/adjust-android.jar.meta new file mode 100644 index 00000000..62add18a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Android/adjust-android.jar.meta @@ -0,0 +1,33 @@ +fileFormatVersion: 2 +guid: de7cd4cf0359345f487233fc82a1d892 +timeCreated: 1526341612 +licenseType: Pro +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': data + second: + enabled: 0 + settings: {} + data: + first: + Android: Android + second: + enabled: 1 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor.meta new file mode 100644 index 00000000..79339fa9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2fc93718626304072a4d2ac17ec632bb +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustEditor.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustEditor.cs new file mode 100644 index 00000000..fa22a2fb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustEditor.cs @@ -0,0 +1,556 @@ +using System; +using System.IO; +using System.Xml; +using System.Collections; +using System.Collections.Generic; +using System.Diagnostics; +using System.Text.RegularExpressions; +using UnityEngine; +using UnityEditor; +using UnityEditor.Callbacks; +#if UNITY_IOS +using UnityEditor.iOS.Xcode; +#endif + +public class AdjustEditor : AssetPostprocessor +{ + [MenuItem("Assets/Adjust/Check iOS 14 Support Status")] + public static void CheckIOS14SupportStatus() + { + EditorUtility.DisplayDialog("Adjust SDK", "iOS 14 support is " + (AdjustSettings.IsiOS14ProcessingEnabled ? "enabled." : "disabled."), "OK"); + } + + [MenuItem("Assets/Adjust/Toggle iOS 14 Support Status")] + public static void ToggleiOS14SupportStatus() + { + AdjustSettings.IsiOS14ProcessingEnabled = !AdjustSettings.IsiOS14ProcessingEnabled; + EditorUtility.SetDirty(AdjustSettings.Instance); + EditorUtility.DisplayDialog("Adjust SDK", "iOS 14 support is now " + (AdjustSettings.IsiOS14ProcessingEnabled ? "enabled." : "disabled.") + + "\nNote: Make sure to save your project files in order for this change to take effect.", "OK"); + } + + [MenuItem("Assets/Adjust/Check Post Processing Status")] + public static void CheckPostProcessingStatus() + { + EditorUtility.DisplayDialog("Adjust SDK", "The post processing for Adjust SDK is " + (AdjustSettings.IsPostProcessingEnabled ? "enabled." : "disabled."), "OK"); + } + + [MenuItem("Assets/Adjust/Toggle Post Processing Status")] + public static void TogglePostProcessingStatus() + { + AdjustSettings.IsPostProcessingEnabled = !AdjustSettings.IsPostProcessingEnabled; + EditorUtility.SetDirty(AdjustSettings.Instance); + EditorUtility.DisplayDialog("Adjust SDK", "The post processing for Adjust SDK is now " + (AdjustSettings.IsPostProcessingEnabled ? "enabled." : "disabled.") + + "\nNote: Make sure to save your project files in order for this change to take effect.", "OK"); + } + + [MenuItem("Assets/Adjust/Export Unity Package")] + public static void ExportAdjustUnityPackage() + { + string exportedFileName = "Adjust.unitypackage"; + string assetsPath = "Assets/Adjust"; + List assetsToExport = new List(); + + // Adjust Assets. + assetsToExport.Add(assetsPath + "/3rd Party/SimpleJSON.cs"); + + assetsToExport.Add(assetsPath + "/Android/adjust-android.jar"); + assetsToExport.Add(assetsPath + "/Android/AdjustAndroid.cs"); + assetsToExport.Add(assetsPath + "/Android/AdjustAndroidManifest.xml"); + + assetsToExport.Add(assetsPath + "/Editor/AdjustEditor.cs"); + assetsToExport.Add(assetsPath + "/Editor/AdjustSettings.cs"); + + assetsToExport.Add(assetsPath + "/ExampleGUI/ExampleGUI.cs"); + assetsToExport.Add(assetsPath + "/ExampleGUI/ExampleGUI.prefab"); + assetsToExport.Add(assetsPath + "/ExampleGUI/ExampleGUI.unity"); + + assetsToExport.Add(assetsPath + "/iOS/ADJAttribution.h"); + assetsToExport.Add(assetsPath + "/iOS/ADJConfig.h"); + assetsToExport.Add(assetsPath + "/iOS/ADJEvent.h"); + assetsToExport.Add(assetsPath + "/iOS/ADJEventFailure.h"); + assetsToExport.Add(assetsPath + "/iOS/ADJEventSuccess.h"); + assetsToExport.Add(assetsPath + "/iOS/ADJLogger.h"); + assetsToExport.Add(assetsPath + "/iOS/ADJSessionFailure.h"); + assetsToExport.Add(assetsPath + "/iOS/ADJSessionSuccess.h"); + assetsToExport.Add(assetsPath + "/iOS/ADJSubscription.h"); + assetsToExport.Add(assetsPath + "/iOS/Adjust.h"); + assetsToExport.Add(assetsPath + "/iOS/AdjustiOS.cs"); + assetsToExport.Add(assetsPath + "/iOS/AdjustSdk.a"); + assetsToExport.Add(assetsPath + "/iOS/AdjustUnity.h"); + assetsToExport.Add(assetsPath + "/iOS/AdjustUnity.mm"); + assetsToExport.Add(assetsPath + "/iOS/AdjustUnityDelegate.h"); + assetsToExport.Add(assetsPath + "/iOS/AdjustUnityDelegate.mm"); + + assetsToExport.Add(assetsPath + "/Prefab/Adjust.prefab"); + + assetsToExport.Add(assetsPath + "/Unity/Adjust.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustAppStoreSubscription.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustAttribution.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustConfig.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustEnvironment.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustEvent.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustEventFailure.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustEventSuccess.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustLogLevel.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustPlayStoreSubscription.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustSessionFailure.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustSessionSuccess.cs"); + assetsToExport.Add(assetsPath + "/Unity/AdjustUtils.cs"); + + assetsToExport.Add(assetsPath + "/Windows/AdjustWindows.cs"); + assetsToExport.Add(assetsPath + "/Windows/WindowsPcl.dll"); + assetsToExport.Add(assetsPath + "/Windows/WindowsUap.dll"); + assetsToExport.Add(assetsPath + "/Windows/Stubs/Win10Interface.dll"); + assetsToExport.Add(assetsPath + "/Windows/Stubs/Win81Interface.dll"); + assetsToExport.Add(assetsPath + "/Windows/Stubs/WinWsInterface.dll"); + assetsToExport.Add(assetsPath + "/Windows/W81/AdjustWP81.dll"); + assetsToExport.Add(assetsPath + "/Windows/W81/Win81Interface.dll"); + assetsToExport.Add(assetsPath + "/Windows/WS/AdjustWS.dll"); + assetsToExport.Add(assetsPath + "/Windows/WS/WinWsInterface.dll"); + assetsToExport.Add(assetsPath + "/Windows/WU10/AdjustUAP10.dll"); + assetsToExport.Add(assetsPath + "/Windows/WU10/Win10Interface.dll"); + assetsToExport.Add(assetsPath + "/Windows/Newtonsoft.Json.dll"); + + AssetDatabase.ExportPackage( + assetsToExport.ToArray(), + exportedFileName, + ExportPackageOptions.IncludeDependencies | ExportPackageOptions.Interactive); + } + + [PostProcessBuild(2)] + public static void OnPostprocessBuild(BuildTarget target, string projectPath) + { + // Check what is user setting about allowing Adjust SDK to perform post build tasks. + // If user disabled it, oh well, we won't do a thing. + if (!AdjustSettings.IsPostProcessingEnabled) + { + UnityEngine.Debug.Log("[Adjust]: You have forbidden the Adjust SDK to perform post processing tasks."); + UnityEngine.Debug.Log("[Adjust]: Skipping post processing tasks."); + return; + } + + RunPostBuildScript(target: target, preBuild: false, projectPath: projectPath); + } + + private static void RunPostBuildScript(BuildTarget target, bool preBuild, string projectPath = "") + { + if (target == BuildTarget.Android) + { + UnityEngine.Debug.Log("[Adjust]: Starting to perform post build tasks for Android platform."); + RunPostProcessTasksAndroid(); + } + else if (target == BuildTarget.iOS) + { +#if UNITY_IOS + UnityEngine.Debug.Log("[Adjust]: Starting to perform post build tasks for iOS platform."); + + string xcodeProjectPath = projectPath + "/Unity-iPhone.xcodeproj/project.pbxproj"; + + PBXProject xcodeProject = new PBXProject(); + xcodeProject.ReadFromFile(xcodeProjectPath); + + // The Adjust SDK will try to add following frameworks to your project: + // - AdSupport.framework (needed for access to IDFA value) + // - iAd.framework (needed in case you are running ASA campaigns) + // - AdServices.framework (needed in case you are running ASA campaigns) + // - CoreTelephony.framework (needed to get information about network type user is connected to) + // - StoreKit.framework (needed for communication with SKAdNetwork framework) + // - AppTrackingTransparency.framework (needed for information about user's consent to be tracked) + + // In case you don't need any of these, feel free to remove them from your app. + +#if UNITY_2019_3_OR_NEWER + string xcodeTarget = xcodeProject.GetUnityFrameworkTargetGuid(); +#else + string xcodeTarget = xcodeProject.TargetGuidByName("Unity-iPhone"); +#endif + + UnityEngine.Debug.Log("[Adjust]: Adding AdSupport.framework to Xcode project."); + xcodeProject.AddFrameworkToProject(xcodeTarget, "AdSupport.framework", true); + UnityEngine.Debug.Log("[Adjust]: AdSupport.framework added successfully."); + + UnityEngine.Debug.Log("[Adjust]: Adding iAd.framework to Xcode project."); + xcodeProject.AddFrameworkToProject(xcodeTarget, "iAd.framework", true); + UnityEngine.Debug.Log("[Adjust]: iAd.framework added successfully."); + + UnityEngine.Debug.Log("[Adjust]: Adding AdServices.framework to Xcode project."); + xcodeProject.AddFrameworkToProject(xcodeTarget, "AdServices.framework", true); + UnityEngine.Debug.Log("[Adjust]: AdServices.framework added successfully."); + + UnityEngine.Debug.Log("[Adjust]: Adding CoreTelephony.framework to Xcode project."); + xcodeProject.AddFrameworkToProject(xcodeTarget, "CoreTelephony.framework", true); + UnityEngine.Debug.Log("[Adjust]: CoreTelephony.framework added successfully."); + + if (AdjustSettings.IsiOS14ProcessingEnabled) + { + UnityEngine.Debug.Log("[Adjust]: Xcode project being built with iOS 14 support."); + + UnityEngine.Debug.Log("[Adjust]: Adding StoreKit.framework to Xcode project."); + xcodeProject.AddFrameworkToProject(xcodeTarget, "StoreKit.framework", true); + UnityEngine.Debug.Log("[Adjust]: StoreKit.framework added successfully."); + + UnityEngine.Debug.Log("[Adjust]: Adding AppTrackingTransparency.framework to Xcode project."); + xcodeProject.AddFrameworkToProject(xcodeTarget, "AppTrackingTransparency.framework", true); + UnityEngine.Debug.Log("[Adjust]: AppTrackingTransparency.framework added successfully."); + } + + // The Adjust SDK needs to have Obj-C exceptions enabled. + // GCC_ENABLE_OBJC_EXCEPTIONS=YES + + UnityEngine.Debug.Log("[Adjust]: Enabling Obj-C exceptions by setting GCC_ENABLE_OBJC_EXCEPTIONS value to YES."); + xcodeProject.AddBuildProperty(xcodeTarget, "GCC_ENABLE_OBJC_EXCEPTIONS", "YES"); + + UnityEngine.Debug.Log("[Adjust]: Obj-C exceptions enabled successfully."); + + // The Adjust SDK needs to have -ObjC flag set in other linker flags section because of it's categories. + // OTHER_LDFLAGS -ObjC + + UnityEngine.Debug.Log("[Adjust]: Adding -ObjC flag to other linker flags (OTHER_LDFLAGS)."); + xcodeProject.AddBuildProperty(xcodeTarget, "OTHER_LDFLAGS", "-ObjC"); + + UnityEngine.Debug.Log("[Adjust]: -ObjC successfully added to other linker flags."); + + if (xcodeProject.ContainsFileByProjectPath("Libraries/Adjust/iOS/AdjustSigSdk.a")) + { + xcodeProject.AddBuildProperty(xcodeTarget, "OTHER_LDFLAGS", "-force_load $(PROJECT_DIR)/Libraries/Adjust/iOS/AdjustSigSdk.a"); + } + + // Save the changes to Xcode project file. + xcodeProject.WriteToFile(xcodeProjectPath); +#endif + } + } + + private static void RunPostProcessTasksiOS(string projectPath) { } + + private static void RunPostProcessTasksAndroid() + { + bool isAdjustManifestUsed = false; + string androidPluginsPath = Path.Combine(Application.dataPath, "Plugins/Android"); + string adjustManifestPath = Path.Combine(Application.dataPath, "JoyPacSDK/Ga_Adjust/Adjust/Android/AdjustAndroidManifest.xml"); + string appManifestPath = Path.Combine(Application.dataPath, "Plugins/Android/AndroidManifest.xml"); + + // Check if user has already created AndroidManifest.xml file in its location. + // If not, use already predefined AdjustAndroidManifest.xml as default one. + if (!File.Exists(appManifestPath)) + { + if (!Directory.Exists(androidPluginsPath)) + { + Directory.CreateDirectory(androidPluginsPath); + } + + isAdjustManifestUsed = true; + File.Copy(adjustManifestPath, appManifestPath); + + UnityEngine.Debug.Log("[Adjust]: User defined AndroidManifest.xml file not found in Plugins/Android folder."); + UnityEngine.Debug.Log("[Adjust]: Creating default app's AndroidManifest.xml from AdjustAndroidManifest.xml file."); + } + else + { + UnityEngine.Debug.Log("[Adjust]: User defined AndroidManifest.xml file located in Plugins/Android folder."); + } + + // If Adjust manifest is used, we have already set up everything in it so that + // our native Android SDK can be used properly. + if (!isAdjustManifestUsed) + { + // However, if you already had your own AndroidManifest.xml, we'll now run + // some checks on it and tweak it a bit if needed to add some stuff which + // our native Android SDK needs so that it can run properly. + + // Let's open the app's AndroidManifest.xml file. + XmlDocument manifestFile = new XmlDocument(); + manifestFile.Load(appManifestPath); + + bool manifestHasChanged = false; + + // Add needed permissions if they are missing. + manifestHasChanged |= AddPermissions(manifestFile); + + // Add intent filter to main activity if it is missing. + manifestHasChanged |= AddBroadcastReceiver(manifestFile); + + if (manifestHasChanged) + { + // Save the changes. + manifestFile.Save(appManifestPath); + + // Clean the manifest file. + CleanManifestFile(appManifestPath); + + UnityEngine.Debug.Log("[Adjust]: App's AndroidManifest.xml file check and potential modification completed."); + UnityEngine.Debug.Log("[Adjust]: Please check if any error message was displayed during this process " + + "and make sure to fix all issues in order to properly use the Adjust SDK in your app."); + } + else + { + UnityEngine.Debug.Log("[Adjust]: App's AndroidManifest.xml file check completed."); + UnityEngine.Debug.Log("[Adjust]: No modifications performed due to app's AndroidManifest.xml file compatibility."); + } + } + } + + private static bool AddPermissions(XmlDocument manifest) + { + // The Adjust SDK needs two permissions to be added to you app's manifest file: + // + // + // + // + + UnityEngine.Debug.Log("[Adjust]: Checking if all permissions needed for the Adjust SDK are present in the app's AndroidManifest.xml file."); + + bool hasInternetPermission = false; + bool hasAccessWifiStatePermission = false; + bool hasAccessNetworkStatePermission = false; + bool hasInstallReferrerServicePermission = false; + + XmlElement manifestRoot = manifest.DocumentElement; + + // Check if permissions are already there. + foreach (XmlNode node in manifestRoot.ChildNodes) + { + if (node.Name == "uses-permission") + { + foreach (XmlAttribute attribute in node.Attributes) + { + if (attribute.Value.Contains("android.permission.INTERNET")) + { + hasInternetPermission = true; + } + else if (attribute.Value.Contains("android.permission.ACCESS_WIFI_STATE")) + { + hasAccessWifiStatePermission = true; + } + else if (attribute.Value.Contains("android.permission.ACCESS_NETWORK_STATE")) + { + hasAccessNetworkStatePermission = true; + } + else if (attribute.Value.Contains("com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE")) + { + hasInstallReferrerServicePermission = true; + } + } + } + } + + bool manifestHasChanged = false; + + // If android.permission.INTERNET permission is missing, add it. + if (!hasInternetPermission) + { + XmlElement element = manifest.CreateElement("uses-permission"); + element.SetAttribute("android__name", "android.permission.INTERNET"); + manifestRoot.AppendChild(element); + UnityEngine.Debug.Log("[Adjust]: android.permission.INTERNET permission successfully added to your app's AndroidManifest.xml file."); + manifestHasChanged = true; + } + else + { + UnityEngine.Debug.Log("[Adjust]: Your app's AndroidManifest.xml file already contains android.permission.INTERNET permission."); + } + + // If android.permission.ACCESS_WIFI_STATE permission is missing, add it. + if (!hasAccessWifiStatePermission) + { + XmlElement element = manifest.CreateElement("uses-permission"); + element.SetAttribute("android__name", "android.permission.ACCESS_WIFI_STATE"); + manifestRoot.AppendChild(element); + UnityEngine.Debug.Log("[Adjust]: android.permission.ACCESS_WIFI_STATE permission successfully added to your app's AndroidManifest.xml file."); + manifestHasChanged = true; + } + else + { + UnityEngine.Debug.Log("[Adjust]: Your app's AndroidManifest.xml file already contains android.permission.ACCESS_WIFI_STATE permission."); + } + + // If android.permission.ACCESS_NETWORK_STATE permission is missing, add it. + if (!hasAccessNetworkStatePermission) + { + XmlElement element = manifest.CreateElement("uses-permission"); + element.SetAttribute("android__name", "android.permission.ACCESS_NETWORK_STATE"); + manifestRoot.AppendChild(element); + UnityEngine.Debug.Log("[Adjust]: android.permission.ACCESS_NETWORK_STATE permission successfully added to your app's AndroidManifest.xml file."); + manifestHasChanged = true; + } + else + { + UnityEngine.Debug.Log("[Adjust]: Your app's AndroidManifest.xml file already contains android.permission.ACCESS_NETWORK_STATE permission."); + } + + // If com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE permission is missing, add it. + if (!hasInstallReferrerServicePermission) + { + XmlElement element = manifest.CreateElement("uses-permission"); + element.SetAttribute("android__name", "com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE"); + manifestRoot.AppendChild(element); + UnityEngine.Debug.Log("[Adjust]: com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE permission successfully added to your app's AndroidManifest.xml file."); + manifestHasChanged = true; + } + else + { + UnityEngine.Debug.Log("[Adjust]: Your app's AndroidManifest.xml file already contains com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE permission."); + } + + return manifestHasChanged; + } + + private static bool AddBroadcastReceiver(XmlDocument manifest) + { + // We're looking for existance of broadcast receiver in the AndroidManifest.xml + // Check out the example below how that usually looks like: + + // > + // + // /> + // + // > + // + // + // + // + // + // + // + // + // + // + // + // > + // + // + + UnityEngine.Debug.Log("[Adjust]: Checking if app's AndroidManifest.xml file contains receiver for INSTALL_REFERRER intent."); + + XmlElement manifestRoot = manifest.DocumentElement; + XmlNode applicationNode = null; + + // Let's find the application node. + foreach (XmlNode node in manifestRoot.ChildNodes) + { + if (node.Name == "application") + { + applicationNode = node; + break; + } + } + + // If there's no applicatio node, something is really wrong with your AndroidManifest.xml. + if (applicationNode == null) + { + UnityEngine.Debug.LogError("[Adjust]: Your app's AndroidManifest.xml file does not contain \"\" node."); + UnityEngine.Debug.LogError("[Adjust]: Unable to add the Adjust broadcast receiver to AndroidManifest.xml."); + return false; + } + + // Okay, there's an application node in the AndroidManifest.xml file. + // Let's now check if user has already defined a receiver which is listening to INSTALL_REFERRER intent. + // If that is already defined, don't force the Adjust broadcast receiver to the manifest file. + // If not, add the Adjust broadcast receiver to the manifest file. + + List customBroadcastReceiversNodes = getCustomRecieverNodes(applicationNode); + if (customBroadcastReceiversNodes.Count > 0) + { + bool foundAdjustBroadcastReceiver = false; + for (int i = 0; i < customBroadcastReceiversNodes.Count; i += 1) + { + foreach (XmlAttribute attribute in customBroadcastReceiversNodes[i].Attributes) + { + if (attribute.Value.Contains("com.adjust.sdk.AdjustReferrerReceiver")) + { + foundAdjustBroadcastReceiver = true; + } + } + } + + if (!foundAdjustBroadcastReceiver) + { + UnityEngine.Debug.Log("[Adjust]: It seems like you are using your own broadcast receiver."); + UnityEngine.Debug.Log("[Adjust]: Please, add the calls to the Adjust broadcast receiver like described in here: https://github.com/adjust/android_sdk/blob/master/doc/english/referrer.md"); + } + else + { + UnityEngine.Debug.Log("[Adjust]: It seems like you are already using Adjust broadcast receiver. Yay."); + } + + return false; + } + else + { + // Generate Adjust broadcast receiver entry and add it to the application node. + XmlElement receiverElement = manifest.CreateElement("receiver"); + receiverElement.SetAttribute("android__name", "com.adjust.sdk.AdjustReferrerReceiver"); + receiverElement.SetAttribute("android__permission", "android.permission.INSTALL_PACKAGES"); + receiverElement.SetAttribute("android__exported", "true"); + + XmlElement intentFilterElement = manifest.CreateElement("intent-filter"); + XmlElement actionElement = manifest.CreateElement("action"); + actionElement.SetAttribute("android__name", "com.android.vending.INSTALL_REFERRER"); + + intentFilterElement.AppendChild(actionElement); + receiverElement.AppendChild(intentFilterElement); + applicationNode.AppendChild(receiverElement); + + UnityEngine.Debug.Log("[Adjust]: Adjust broadcast receiver successfully added to your app's AndroidManifest.xml file."); + + return true; + } + } + + private static void CleanManifestFile(String manifestPath) + { + // Due to XML writing issue with XmlElement methods which are unable + // to write "android:[param]" string, we have wrote "android__[param]" string instead. + // Now make the replacement: "android:[param]" -> "android__[param]" + + TextReader manifestReader = new StreamReader(manifestPath); + string manifestContent = manifestReader.ReadToEnd(); + manifestReader.Close(); + + Regex regex = new Regex("android__"); + manifestContent = regex.Replace(manifestContent, "android:"); + + TextWriter manifestWriter = new StreamWriter(manifestPath); + manifestWriter.Write(manifestContent); + manifestWriter.Close(); + } + + private static List getCustomRecieverNodes(XmlNode applicationNode) + { + List nodes = new List(); + foreach (XmlNode node in applicationNode.ChildNodes) + { + if (node.Name == "receiver") + { + foreach (XmlNode subnode in node.ChildNodes) + { + if (subnode.Name == "intent-filter") + { + foreach (XmlNode subsubnode in subnode.ChildNodes) + { + if (subsubnode.Name == "action") + { + foreach (XmlAttribute attribute in subsubnode.Attributes) + { + if (attribute.Value.Contains("com.android.vending.INSTALL_REFERRER")) + { + nodes.Add(node); + } + } + } + } + } + } + } + } + return nodes; + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustEditor.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustEditor.cs.meta new file mode 100644 index 00000000..13983a54 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustEditor.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fc5962e0096e9495bbad76934c842619 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.asset b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.asset new file mode 100644 index 00000000..3a675b71 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.asset @@ -0,0 +1,16 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: ea4d495dc6d5ba64b90db7afda6a48a4, type: 3} + m_Name: AdjustSettings + m_EditorClassIdentifier: + isPostProcessingEnabled: 1 + isiOS14ProcessingEnabled: 0 diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.asset.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.asset.meta new file mode 100644 index 00000000..55640258 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 44629b0f1e2294c47820d5fe00a86603 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 11400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.cs new file mode 100644 index 00000000..1256823d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.cs @@ -0,0 +1,102 @@ +// Inspired by: https://github.com/facebook/facebook-sdk-for-unity/blob/master/Facebook.Unity.Settings/FacebookSettings.cs + +using System; +using System.IO; +using UnityEditor; +using UnityEngine; + +public class AdjustSettings : ScriptableObject +{ + private static AdjustSettings instance; + + [SerializeField] + private bool isPostProcessingEnabled = true; + [SerializeField] + private bool isiOS14ProcessingEnabled = false; + + public static AdjustSettings Instance + { + get + { + instance = NullableInstance; + + if (instance == null) + { + // Create AdjustSettings.asset inside the folder in which AdjustSettings.cs reside. + instance = ScriptableObject.CreateInstance(); + var guids = AssetDatabase.FindAssets(string.Format("{0} t:script", "AdjustSettings")); + if (guids == null || guids.Length <= 0) + { + return instance; + } + var assetPath = AssetDatabase.GUIDToAssetPath(guids[0]).Replace("AdjustSettings.cs", "AdjustSettings.asset"); + AssetDatabase.CreateAsset(instance, assetPath); + + // Before switching to AssetsDatabase, EditorPrefs were used to write 'adjustiOS14Support' key. + // Check if this key still exists in EditorPrefs. + // If yes, migrate the value to AdjustSettings.asset and remove the key from EditorPrefs. + if (EditorPrefs.HasKey("adjustiOS14Support")) + { + UnityEngine.Debug.Log("[Adjust]: Found 'adjustiOS14Support' key in EditorPrefs."); + UnityEngine.Debug.Log("[Adjust]: Migrating that value to AdjustSettings.asset."); + IsiOS14ProcessingEnabled = EditorPrefs.GetBool("adjustiOS14Support", false); + EditorPrefs.DeleteKey("adjustiOS14Support"); + UnityEngine.Debug.Log("[Adjust]: Key 'adjustiOS14Support' removed from EditorPrefs."); + } + } + + return instance; + } + } + + public static AdjustSettings NullableInstance + { + get + { + if (instance == null) + { + var guids = AssetDatabase.FindAssets(string.Format("{0} t:ScriptableObject", "AdjustSettings")); + if (guids == null || guids.Length <= 0) + { + return instance; + } + var assetPath = AssetDatabase.GUIDToAssetPath(guids[0]); + instance = (AdjustSettings)AssetDatabase.LoadAssetAtPath(assetPath, typeof(AdjustSettings)); + } + + return instance; + } + } + + public static bool IsPostProcessingEnabled + { + get + { + return Instance.isPostProcessingEnabled; + } + + set + { + if (Instance.isPostProcessingEnabled != value) + { + Instance.isPostProcessingEnabled = value; + } + } + } + + public static bool IsiOS14ProcessingEnabled + { + get + { + return Instance.isiOS14ProcessingEnabled; + } + + set + { + if (Instance.isiOS14ProcessingEnabled != value) + { + Instance.isiOS14ProcessingEnabled = value; + } + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.cs.meta new file mode 100644 index 00000000..aefcdd09 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Editor/AdjustSettings.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: ea4d495dc6d5ba64b90db7afda6a48a4 +timeCreated: 1601333126 +licenseType: Pro +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI.meta new file mode 100644 index 00000000..f353f950 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 118ae8ed09c7541c891a03228788e481 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.cs new file mode 100755 index 00000000..57a5490a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.cs @@ -0,0 +1,290 @@ +using System; +using System.Text; +using System.Collections; +using System.Runtime.InteropServices; +using UnityEngine; +using UnityEngine.UI; +using com.adjust.sdk; + +public class ExampleGUI : MonoBehaviour +{ + private int numberOfButtons = 8; + private bool isEnabled; + private bool showPopUp = false; + private string txtSetEnabled = "Disable SDK"; + private string txtManualLaunch = "Manual Launch"; + private string txtSetOfflineMode = "Turn Offline Mode ON"; + + void OnGUI() + { + if (showPopUp) + { + GUI.Window(0, new Rect((Screen.width / 2) - 150, (Screen.height / 2) - 65, 300, 130), ShowGUI, "Is SDK enabled?"); + } + + if (GUI.Button(new Rect(0, Screen.height * 0 / numberOfButtons, Screen.width, Screen.height / numberOfButtons), txtManualLaunch)) + { + if (!string.Equals(txtManualLaunch, "SDK Launched", StringComparison.OrdinalIgnoreCase)) + { + AdjustConfig adjustConfig = new AdjustConfig("2fm9gkqubvpc", AdjustEnvironment.Sandbox); + adjustConfig.setLogLevel(AdjustLogLevel.Verbose); + adjustConfig.setLogDelegate(msg => Debug.Log(msg)); + adjustConfig.setEventSuccessDelegate(EventSuccessCallback); + adjustConfig.setEventFailureDelegate(EventFailureCallback); + adjustConfig.setSessionSuccessDelegate(SessionSuccessCallback); + adjustConfig.setSessionFailureDelegate(SessionFailureCallback); + adjustConfig.setDeferredDeeplinkDelegate(DeferredDeeplinkCallback); + adjustConfig.setAttributionChangedDelegate(AttributionChangedCallback); + Adjust.start(adjustConfig); + + isEnabled = true; + txtManualLaunch = "SDK Launched"; + } + } + + if (GUI.Button(new Rect(0, Screen.height * 1 / numberOfButtons, Screen.width, Screen.height / numberOfButtons), "Track Simple Event")) + { + AdjustEvent adjustEvent = new AdjustEvent("g3mfiw"); + Adjust.trackEvent(adjustEvent); + } + + if (GUI.Button(new Rect(0, Screen.height * 2 / numberOfButtons, Screen.width, Screen.height / numberOfButtons), "Track Revenue Event")) + { + AdjustEvent adjustEvent = new AdjustEvent("a4fd35"); + adjustEvent.setRevenue(0.25, "EUR"); + Adjust.trackEvent(adjustEvent); + } + + if (GUI.Button(new Rect(0, Screen.height * 3 / numberOfButtons, Screen.width, Screen.height / numberOfButtons), "Track Callback Event")) + { + AdjustEvent adjustEvent = new AdjustEvent("34vgg9"); + adjustEvent.addCallbackParameter("key", "value"); + adjustEvent.addCallbackParameter("foo", "bar"); + Adjust.trackEvent(adjustEvent); + } + + if (GUI.Button(new Rect(0, Screen.height * 4 / numberOfButtons, Screen.width, Screen.height / numberOfButtons), "Track Partner Event")) + { + AdjustEvent adjustEvent = new AdjustEvent("w788qs"); + adjustEvent.addPartnerParameter("key", "value"); + adjustEvent.addPartnerParameter("foo", "bar"); + Adjust.trackEvent(adjustEvent); + } + + if (GUI.Button(new Rect(0, Screen.height * 5 / numberOfButtons, Screen.width, Screen.height / numberOfButtons), txtSetOfflineMode)) + { + if (string.Equals(txtSetOfflineMode, "Turn Offline Mode ON", StringComparison.OrdinalIgnoreCase)) + { + Adjust.setOfflineMode(true); + txtSetOfflineMode = "Turn Offline Mode OFF"; + } + else + { + Adjust.setOfflineMode(false); + txtSetOfflineMode = "Turn Offline Mode ON"; + } + } + + if (GUI.Button(new Rect(0, Screen.height * 6 / numberOfButtons, Screen.width, Screen.height / numberOfButtons), txtSetEnabled)) + { + if (string.Equals(txtSetEnabled, "Disable SDK", StringComparison.OrdinalIgnoreCase)) + { + Adjust.setEnabled(false); + txtSetEnabled = "Enable SDK"; + } + else + { + Adjust.setEnabled(true); + txtSetEnabled = "Disable SDK"; + } + } + + if (GUI.Button(new Rect(0, Screen.height * 7 / numberOfButtons, Screen.width, Screen.height / numberOfButtons), "Is SDK Enabled?")) + { + isEnabled = Adjust.isEnabled(); + showPopUp = true; + } + } + + void ShowGUI(int windowID) + { + if (isEnabled) + { + GUI.Label(new Rect(65, 40, 200, 30), "Adjust SDK is ENABLED!"); + } + else + { + GUI.Label(new Rect(65, 40, 200, 30), "Adjust SDK is DISABLED!"); + } + + if (GUI.Button(new Rect(90, 75, 120, 40), "OK")) + { + showPopUp = false; + } + } + + public void HandleGooglePlayId(String adId) + { + Debug.Log("Google Play Ad ID = " + adId); + } + + public void AttributionChangedCallback(AdjustAttribution attributionData) + { + Debug.Log("Attribution changed!"); + + if (attributionData.trackerName != null) + { + Debug.Log("Tracker name: " + attributionData.trackerName); + } + if (attributionData.trackerToken != null) + { + Debug.Log("Tracker token: " + attributionData.trackerToken); + } + if (attributionData.network != null) + { + Debug.Log("Network: " + attributionData.network); + } + if (attributionData.campaign != null) + { + Debug.Log("Campaign: " + attributionData.campaign); + } + if (attributionData.adgroup != null) + { + Debug.Log("Adgroup: " + attributionData.adgroup); + } + if (attributionData.creative != null) + { + Debug.Log("Creative: " + attributionData.creative); + } + if (attributionData.clickLabel != null) + { + Debug.Log("Click label: " + attributionData.clickLabel); + } + if (attributionData.adid != null) + { + Debug.Log("ADID: " + attributionData.adid); + } + } + + public void EventSuccessCallback(AdjustEventSuccess eventSuccessData) + { + Debug.Log("Event tracked successfully!"); + + if (eventSuccessData.Message != null) + { + Debug.Log("Message: " + eventSuccessData.Message); + } + if (eventSuccessData.Timestamp != null) + { + Debug.Log("Timestamp: " + eventSuccessData.Timestamp); + } + if (eventSuccessData.Adid != null) + { + Debug.Log("Adid: " + eventSuccessData.Adid); + } + if (eventSuccessData.EventToken != null) + { + Debug.Log("EventToken: " + eventSuccessData.EventToken); + } + if (eventSuccessData.CallbackId != null) + { + Debug.Log("CallbackId: " + eventSuccessData.CallbackId); + } + if (eventSuccessData.JsonResponse != null) + { + Debug.Log("JsonResponse: " + eventSuccessData.GetJsonResponse()); + } + } + + public void EventFailureCallback(AdjustEventFailure eventFailureData) + { + Debug.Log("Event tracking failed!"); + + if (eventFailureData.Message != null) + { + Debug.Log("Message: " + eventFailureData.Message); + } + if (eventFailureData.Timestamp != null) + { + Debug.Log("Timestamp: " + eventFailureData.Timestamp); + } + if (eventFailureData.Adid != null) + { + Debug.Log("Adid: " + eventFailureData.Adid); + } + if (eventFailureData.EventToken != null) + { + Debug.Log("EventToken: " + eventFailureData.EventToken); + } + if (eventFailureData.CallbackId != null) + { + Debug.Log("CallbackId: " + eventFailureData.CallbackId); + } + if (eventFailureData.JsonResponse != null) + { + Debug.Log("JsonResponse: " + eventFailureData.GetJsonResponse()); + } + + Debug.Log("WillRetry: " + eventFailureData.WillRetry.ToString()); + } + + public void SessionSuccessCallback(AdjustSessionSuccess sessionSuccessData) + { + Debug.Log("Session tracked successfully!"); + + if (sessionSuccessData.Message != null) + { + Debug.Log("Message: " + sessionSuccessData.Message); + } + if (sessionSuccessData.Timestamp != null) + { + Debug.Log("Timestamp: " + sessionSuccessData.Timestamp); + } + if (sessionSuccessData.Adid != null) + { + Debug.Log("Adid: " + sessionSuccessData.Adid); + } + if (sessionSuccessData.JsonResponse != null) + { + Debug.Log("JsonResponse: " + sessionSuccessData.GetJsonResponse()); + } + } + + public void SessionFailureCallback(AdjustSessionFailure sessionFailureData) + { + Debug.Log("Session tracking failed!"); + + if (sessionFailureData.Message != null) + { + Debug.Log("Message: " + sessionFailureData.Message); + } + if (sessionFailureData.Timestamp != null) + { + Debug.Log("Timestamp: " + sessionFailureData.Timestamp); + } + if (sessionFailureData.Adid != null) + { + Debug.Log("Adid: " + sessionFailureData.Adid); + } + if (sessionFailureData.JsonResponse != null) + { + Debug.Log("JsonResponse: " + sessionFailureData.GetJsonResponse()); + } + + Debug.Log("WillRetry: " + sessionFailureData.WillRetry.ToString()); + } + + private void DeferredDeeplinkCallback(string deeplinkURL) + { + Debug.Log("Deferred deeplink reported!"); + + if (deeplinkURL != null) + { + Debug.Log("Deeplink URL: " + deeplinkURL); + } + else + { + Debug.Log("Deeplink URL is null!"); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.cs.meta new file mode 100755 index 00000000..b52508ef --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 196c5c89d4b1e46dfbf423ae77d31a68 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.prefab b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.prefab new file mode 100755 index 00000000..377b5082 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.prefab @@ -0,0 +1,53 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &100000 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 400000} + - component: {fileID: 11400000} + m_Layer: 0 + m_Name: ExampleGUI + m_TagString: MainCamera + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &400000 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1, z: -10} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 196c5c89d4b1e46dfbf423ae77d31a68, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 100000} + m_IsPrefabParent: 1 diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.prefab.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.prefab.meta new file mode 100755 index 00000000..e70eb6c2 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 50b53da2a7a154d63a33a49ad08c24a8 +NativeFormatImporter: + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.unity b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.unity new file mode 100755 index 00000000..5026f265 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.unity @@ -0,0 +1,292 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!29 &1 +OcclusionCullingSettings: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_OcclusionBakeSettings: + smallestOccluder: 5 + smallestHole: 0.25 + backfaceThreshold: 100 + m_SceneGUID: 00000000000000000000000000000000 + m_OcclusionCullingData: {fileID: 0} +--- !u!104 &2 +RenderSettings: + m_ObjectHideFlags: 0 + serializedVersion: 8 + m_Fog: 0 + m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1} + m_FogMode: 3 + m_FogDensity: 0.01 + m_LinearFogStart: 0 + m_LinearFogEnd: 300 + m_AmbientSkyColor: {r: 0.2, g: 0.2, b: 0.2, a: 1} + m_AmbientEquatorColor: {r: 0.2, g: 0.2, b: 0.2, a: 1} + m_AmbientGroundColor: {r: 0.2, g: 0.2, b: 0.2, a: 1} + m_AmbientIntensity: 1 + m_AmbientMode: 3 + m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1} + m_SkyboxMaterial: {fileID: 0} + m_HaloStrength: 0.5 + m_FlareStrength: 1 + m_FlareFadeSpeed: 3 + m_HaloTexture: {fileID: 0} + m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} + m_DefaultReflectionMode: 0 + m_DefaultReflectionResolution: 128 + m_ReflectionBounces: 1 + m_ReflectionIntensity: 1 + m_CustomReflection: {fileID: 0} + m_Sun: {fileID: 0} + m_IndirectSpecularColor: {r: 0, g: 0, b: 0, a: 1} +--- !u!157 &4 +LightmapSettings: + m_ObjectHideFlags: 0 + serializedVersion: 11 + m_GIWorkflowMode: 1 + m_GISettings: + serializedVersion: 2 + m_BounceScale: 1 + m_IndirectOutputScale: 1 + m_AlbedoBoost: 1 + m_TemporalCoherenceThreshold: 1 + m_EnvironmentLightingMode: 0 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_LightmapEditorSettings: + serializedVersion: 9 + m_Resolution: 1 + m_BakeResolution: 50 + m_TextureWidth: 1024 + m_TextureHeight: 1024 + m_AO: 0 + m_AOMaxDistance: 1 + m_CompAOExponent: 0 + m_CompAOExponentDirect: 0 + m_Padding: 2 + m_LightmapParameters: {fileID: 0} + m_LightmapsBakeMode: 1 + m_TextureCompression: 0 + m_FinalGather: 0 + m_FinalGatherFiltering: 1 + m_FinalGatherRayCount: 1024 + m_ReflectionCompression: 2 + m_MixedBakeMode: 1 + m_BakeBackend: 0 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 500 + m_PVRBounces: 2 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVRFilteringMode: 0 + m_PVRCulling: 1 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 + m_ShowResolutionOverlay: 1 + m_LightingDataAsset: {fileID: 0} + m_UseShadowmask: 0 +--- !u!196 &5 +NavMeshSettings: + serializedVersion: 2 + m_ObjectHideFlags: 0 + m_BuildSettings: + serializedVersion: 2 + agentTypeID: 0 + agentRadius: 0.5 + agentHeight: 2 + agentSlope: 45 + agentClimb: 0.4 + ledgeDropHeight: 0 + maxJumpAcrossDistance: 0 + minRegionArea: 2 + manualCellSize: 0 + cellSize: 0.16666666 + manualTileSize: 0 + tileSize: 256 + accuratePlacement: 0 + debug: + m_Flags: 0 + m_NavMeshData: {fileID: 0} +--- !u!1001 &7284787 +Prefab: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: + - target: {fileID: 415478, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 415478, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 415478, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 415478, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 415478, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 415478, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 415478, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 415478, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: m_RootOrder + value: 2 + objectReference: {fileID: 0} + - target: {fileID: 11482148, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: startManually + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 11482148, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: logLevel + value: 3 + objectReference: {fileID: 0} + - target: {fileID: 11482148, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + propertyPath: appToken + value: '{YourAppToken}' + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 100100000, guid: a3267720e82aa41c1a05ab29824902b4, type: 2} + m_IsPrefabParent: 0 +--- !u!1 &231489158 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 231489162} + - component: {fileID: 231489161} + - component: {fileID: 231489160} + - component: {fileID: 231489159} + m_Layer: 0 + m_Name: Camera + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!81 &231489159 +AudioListener: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 231489158} + m_Enabled: 1 +--- !u!124 &231489160 +Behaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 231489158} + m_Enabled: 1 +--- !u!20 &231489161 +Camera: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 231489158} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0} + m_NormalizedViewPortRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 1 + height: 1 + near clip plane: 0.3 + far clip plane: 1000 + field of view: 60 + orthographic: 0 + orthographic size: 5 + m_Depth: 0 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingPath: -1 + m_TargetTexture: {fileID: 0} + m_TargetDisplay: 0 + m_TargetEye: 3 + m_HDR: 1 + m_AllowMSAA: 1 + m_AllowDynamicResolution: 0 + m_ForceIntoRT: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 +--- !u!4 &231489162 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 231489158} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1001 &1861285553 +Prefab: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: + - target: {fileID: 400000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 400000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + propertyPath: m_LocalPosition.y + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 400000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + propertyPath: m_LocalPosition.z + value: -10 + objectReference: {fileID: 0} + - target: {fileID: 400000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 400000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 400000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 400000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 400000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + propertyPath: m_RootOrder + value: 1 + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 100100000, guid: 50b53da2a7a154d63a33a49ad08c24a8, type: 2} + m_IsPrefabParent: 0 diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.unity.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.unity.meta new file mode 100755 index 00000000..60d5d95f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/ExampleGUI/ExampleGUI.unity.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6aa8afcd558084586bce9f8efd3eb5d6 +timeCreated: 1447689503 +licenseType: Pro +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab.meta new file mode 100644 index 00000000..28115ee5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c760e2a2f446a43b48e7db2a5cba9cca +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab/Adjust.prefab b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab/Adjust.prefab new file mode 100755 index 00000000..8ee1dc02 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab/Adjust.prefab @@ -0,0 +1,60 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &115478 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 415478} + - component: {fileID: 11482148} + m_Layer: 0 + m_Name: Adjust + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &415478 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115478} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &11482148 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115478} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 525ece82a472e4dea837e1ef938fd15d, type: 3} + m_Name: + m_EditorClassIdentifier: + startManually: 1 + eventBuffering: 0 + sendInBackground: 0 + launchDeferredDeeplink: 1 + appToken: '{Your App Token}' + logLevel: 3 + environment: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 115478} + m_IsPrefabParent: 1 diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab/Adjust.prefab.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab/Adjust.prefab.meta new file mode 100755 index 00000000..ca669372 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Prefab/Adjust.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: a3267720e82aa41c1a05ab29824902b4 +NativeFormatImporter: + mainObjectFileID: -1 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity.meta new file mode 100644 index 00000000..f3390a19 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c5f495a1b96de4701a83193585b8a76c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/Adjust.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/Adjust.cs new file mode 100644 index 00000000..f49bba12 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/Adjust.cs @@ -0,0 +1,854 @@ +using System; +using System.Collections.Generic; +using UnityEngine; + +namespace com.adjust.sdk +{ + public class Adjust : MonoBehaviour + { + private const string errorMsgEditor = "[Adjust]: SDK can not be used in Editor."; + private const string errorMsgStart = "[Adjust]: SDK not started. Start it manually using the 'start' method."; + private const string errorMsgPlatform = "[Adjust]: SDK can only be used in Android, iOS, Windows Phone 8.1, Windows Store or Universal Windows apps."; + + public bool startManually = true; + public bool eventBuffering = false; + public bool sendInBackground = false; + public bool launchDeferredDeeplink = true; + + public string appToken = "{Your App Token}"; + + public AdjustLogLevel logLevel = AdjustLogLevel.Info; + public AdjustEnvironment environment = AdjustEnvironment.Sandbox; + +#if UNITY_IOS + // Delegate references for iOS callback triggering + private static List> authorizationStatusDelegates = null; + private static Action deferredDeeplinkDelegate = null; + private static Action eventSuccessDelegate = null; + private static Action eventFailureDelegate = null; + private static Action sessionSuccessDelegate = null; + private static Action sessionFailureDelegate = null; + private static Action attributionChangedDelegate = null; +#endif + + void Awake() + { + if (IsEditor()) + { + return; + } + + DontDestroyOnLoad(transform.gameObject); + + if (!this.startManually) + { + AdjustConfig adjustConfig = new AdjustConfig(this.appToken, this.environment, (this.logLevel == AdjustLogLevel.Suppress)); + adjustConfig.setLogLevel(this.logLevel); + adjustConfig.setSendInBackground(this.sendInBackground); + adjustConfig.setEventBufferingEnabled(this.eventBuffering); + adjustConfig.setLaunchDeferredDeeplink(this.launchDeferredDeeplink); + Adjust.start(adjustConfig); + } + } + + void OnApplicationPause(bool pauseStatus) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + // No action, iOS SDK is subscribed to iOS lifecycle notifications. +#elif UNITY_ANDROID + if (pauseStatus) + { + AdjustAndroid.OnPause(); + } + else + { + AdjustAndroid.OnResume(); + } +#elif (UNITY_WSA || UNITY_WP8) + if (pauseStatus) + { + AdjustWindows.OnPause(); + } + else + { + AdjustWindows.OnResume(); + } +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void start(AdjustConfig adjustConfig) + { + if (IsEditor()) + { + return; + } + + if (adjustConfig == null) + { + Debug.Log("[Adjust]: Missing config to start."); + return; + } + +#if UNITY_IOS + Adjust.eventSuccessDelegate = adjustConfig.getEventSuccessDelegate(); + Adjust.eventFailureDelegate = adjustConfig.getEventFailureDelegate(); + Adjust.sessionSuccessDelegate = adjustConfig.getSessionSuccessDelegate(); + Adjust.sessionFailureDelegate = adjustConfig.getSessionFailureDelegate(); + Adjust.deferredDeeplinkDelegate = adjustConfig.getDeferredDeeplinkDelegate(); + Adjust.attributionChangedDelegate = adjustConfig.getAttributionChangedDelegate(); + AdjustiOS.Start(adjustConfig); +#elif UNITY_ANDROID + AdjustAndroid.Start(adjustConfig); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.Start(adjustConfig); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void trackEvent(AdjustEvent adjustEvent) + { + if (IsEditor()) + { + return; + } + + if (adjustEvent == null) + { + Debug.Log("[Adjust]: Missing event to track."); + return; + } +#if UNITY_IOS + AdjustiOS.TrackEvent(adjustEvent); +#elif UNITY_ANDROID + AdjustAndroid.TrackEvent(adjustEvent); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.TrackEvent(adjustEvent); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void setEnabled(bool enabled) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.SetEnabled(enabled); +#elif UNITY_ANDROID + AdjustAndroid.SetEnabled(enabled); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.SetEnabled(enabled); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static bool isEnabled() + { + if (IsEditor()) + { + return false; + } + +#if UNITY_IOS + return AdjustiOS.IsEnabled(); +#elif UNITY_ANDROID + return AdjustAndroid.IsEnabled(); +#elif (UNITY_WSA || UNITY_WP8) + return AdjustWindows.IsEnabled(); +#else + Debug.Log(errorMsgPlatform); + return false; +#endif + } + + public static void setOfflineMode(bool enabled) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.SetOfflineMode(enabled); +#elif UNITY_ANDROID + AdjustAndroid.SetOfflineMode(enabled); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.SetOfflineMode(enabled); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void setDeviceToken(string deviceToken) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.SetDeviceToken(deviceToken); +#elif UNITY_ANDROID + AdjustAndroid.SetDeviceToken(deviceToken); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.SetDeviceToken(deviceToken); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void gdprForgetMe() + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.GdprForgetMe(); +#elif UNITY_ANDROID + AdjustAndroid.GdprForgetMe(); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.GdprForgetMe(); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void disableThirdPartySharing() + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.DisableThirdPartySharing(); +#elif UNITY_ANDROID + AdjustAndroid.DisableThirdPartySharing(); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Disable third party sharing is only supported for Android and iOS platforms."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void appWillOpenUrl(string url) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.AppWillOpenUrl(url); +#elif UNITY_ANDROID + AdjustAndroid.AppWillOpenUrl(url); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.AppWillOpenUrl(url); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void sendFirstPackages() + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.SendFirstPackages(); +#elif UNITY_ANDROID + AdjustAndroid.SendFirstPackages(); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.SendFirstPackages(); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void addSessionPartnerParameter(string key, string value) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.AddSessionPartnerParameter(key, value); +#elif UNITY_ANDROID + AdjustAndroid.AddSessionPartnerParameter(key, value); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.AddSessionPartnerParameter(key, value); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void addSessionCallbackParameter(string key, string value) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.AddSessionCallbackParameter(key, value); +#elif UNITY_ANDROID + AdjustAndroid.AddSessionCallbackParameter(key, value); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.AddSessionCallbackParameter(key, value); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void removeSessionPartnerParameter(string key) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.RemoveSessionPartnerParameter(key); +#elif UNITY_ANDROID + AdjustAndroid.RemoveSessionPartnerParameter(key); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.RemoveSessionPartnerParameter(key); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void removeSessionCallbackParameter(string key) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.RemoveSessionCallbackParameter(key); +#elif UNITY_ANDROID + AdjustAndroid.RemoveSessionCallbackParameter(key); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.RemoveSessionCallbackParameter(key); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void resetSessionPartnerParameters() + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.ResetSessionPartnerParameters(); +#elif UNITY_ANDROID + AdjustAndroid.ResetSessionPartnerParameters(); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.ResetSessionPartnerParameters(); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void resetSessionCallbackParameters() + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.ResetSessionCallbackParameters(); +#elif UNITY_ANDROID + AdjustAndroid.ResetSessionCallbackParameters(); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.ResetSessionCallbackParameters(); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void trackAdRevenue(string source, string payload) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.TrackAdRevenue(source, payload); +#elif UNITY_ANDROID + AdjustAndroid.TrackAdRevenue(source, payload); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Ad revenue tracking is only supported for Android and iOS platforms."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void trackAppStoreSubscription(AdjustAppStoreSubscription subscription) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.TrackAppStoreSubscription(subscription); +#elif UNITY_ANDROID + Debug.Log("[Adjust]: App Store subscription tracking is only supported for iOS platform."); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: App Store subscription tracking is only supported for iOS platform."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void trackPlayStoreSubscription(AdjustPlayStoreSubscription subscription) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + Debug.Log("[Adjust]: Play Store subscription tracking is only supported for Android platform."); +#elif UNITY_ANDROID + AdjustAndroid.TrackPlayStoreSubscription(subscription); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Play Store subscription tracking is only supported for Android platform."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void trackThirdPartySharing(AdjustThirdPartySharing thirdPartySharing) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.TrackThirdPartySharing(thirdPartySharing); +#elif UNITY_ANDROID + AdjustAndroid.TrackThirdPartySharing(thirdPartySharing); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Third party sharing tracking is only supported for iOS and Android platforms."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void trackMeasurementConsent(bool measurementConsent) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.TrackMeasurementConsent(measurementConsent); +#elif UNITY_ANDROID + AdjustAndroid.TrackMeasurementConsent(measurementConsent); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Measurement consent tracking is only supported for iOS and Android platforms."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void requestTrackingAuthorizationWithCompletionHandler(Action statusCallback, string sceneName = "Adjust") + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + if (Adjust.authorizationStatusDelegates == null) + { + Adjust.authorizationStatusDelegates = new List>(); + } + Adjust.authorizationStatusDelegates.Add(statusCallback); + AdjustiOS.RequestTrackingAuthorizationWithCompletionHandler(sceneName); +#elif UNITY_ANDROID + Debug.Log("[Adjust]: Requesting tracking authorization is only supported for iOS platform."); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Requesting tracking authorization is only supported for iOS platform."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void updateConversionValue(int conversionValue) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.UpdateConversionValue(conversionValue); +#elif UNITY_ANDROID + Debug.Log("[Adjust]: Updating SKAdNetwork conversion value is only supported for iOS platform."); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Updating SKAdNetwork conversion value is only supported for iOS platform."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static int getAppTrackingAuthorizationStatus() + { + if (IsEditor()) + { + return -1; + } + +#if UNITY_IOS + return AdjustiOS.GetAppTrackingAuthorizationStatus(); +#elif UNITY_ANDROID + Debug.Log("[Adjust]: Error! App tracking authorization status is only supported for iOS platform."); + return -1; +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Error! App tracking authorization status is only supported for iOS platform."); + return -1; +#else + Debug.Log(errorMsgPlatform); + return -1; +#endif + } + + public static string getAdid() + { + if (IsEditor()) + { + return string.Empty; + } + +#if UNITY_IOS + return AdjustiOS.GetAdid(); +#elif UNITY_ANDROID + return AdjustAndroid.GetAdid(); +#elif (UNITY_WSA || UNITY_WP8) + return AdjustWindows.GetAdid(); +#else + Debug.Log(errorMsgPlatform); + return string.Empty; +#endif + } + + public static AdjustAttribution getAttribution() + { + if (IsEditor()) + { + return null; + } + +#if UNITY_IOS + return AdjustiOS.GetAttribution(); +#elif UNITY_ANDROID + return AdjustAndroid.GetAttribution(); +#elif (UNITY_WSA || UNITY_WP8) + return AdjustWindows.GetAttribution(); +#else + Debug.Log(errorMsgPlatform); + return null; +#endif + } + + public static string getWinAdid() + { + if (IsEditor()) + { + return string.Empty; + } + +#if UNITY_IOS + Debug.Log("[Adjust]: Error! Windows Advertising ID is not available on iOS platform."); + return string.Empty; +#elif UNITY_ANDROID + Debug.Log("[Adjust]: Error! Windows Advertising ID is not available on Android platform."); + return string.Empty; +#elif (UNITY_WSA || UNITY_WP8) + return AdjustWindows.GetWinAdId(); +#else + Debug.Log(errorMsgPlatform); + return string.Empty; +#endif + } + + public static string getIdfa() + { + if (IsEditor()) + { + return string.Empty; + } + +#if UNITY_IOS + return AdjustiOS.GetIdfa(); +#elif UNITY_ANDROID + Debug.Log("[Adjust]: Error! IDFA is not available on Android platform."); + return string.Empty; +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Error! IDFA is not available on Windows platform."); + return string.Empty; +#else + Debug.Log(errorMsgPlatform); + return string.Empty; +#endif + } + + public static string getSdkVersion() + { + if (IsEditor()) + { + return string.Empty; + } + +#if UNITY_IOS + return AdjustiOS.GetSdkVersion(); +#elif UNITY_ANDROID + return AdjustAndroid.GetSdkVersion(); +#elif (UNITY_WSA || UNITY_WP8) + return AdjustWindows.GetSdkVersion(); +#else + Debug.Log(errorMsgPlatform); + return string.Empty; +#endif + } + + [Obsolete("This method is intended for testing purposes only. Do not use it.")] + public static void setReferrer(string referrer) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + Debug.Log("[Adjust]: Install referrer is not available on iOS platform."); +#elif UNITY_ANDROID + AdjustAndroid.SetReferrer(referrer); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Error! Install referrer is not available on Windows platform."); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void getGoogleAdId(Action onDeviceIdsRead) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + Debug.Log("[Adjust]: Google Play Advertising ID is not available on iOS platform."); + onDeviceIdsRead(string.Empty); +#elif UNITY_ANDROID + AdjustAndroid.GetGoogleAdId(onDeviceIdsRead); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Google Play Advertising ID is not available on Windows platform."); + onDeviceIdsRead(string.Empty); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static string getAmazonAdId() + { + if (IsEditor()) + { + return string.Empty; + } + +#if UNITY_IOS + Debug.Log("[Adjust]: Amazon Advertising ID is not available on iOS platform."); + return string.Empty; +#elif UNITY_ANDROID + return AdjustAndroid.GetAmazonAdId(); +#elif (UNITY_WSA || UNITY_WP8) + Debug.Log("[Adjust]: Amazon Advertising ID not available on Windows platform."); + return string.Empty; +#else + Debug.Log(errorMsgPlatform); + return string.Empty; +#endif + } + +#if UNITY_IOS + public void GetNativeAttribution(string attributionData) + { + if (IsEditor()) + { + return; + } + + if (Adjust.attributionChangedDelegate == null) + { + Debug.Log("[Adjust]: Attribution changed delegate was not set."); + return; + } + + var attribution = new AdjustAttribution(attributionData); + Adjust.attributionChangedDelegate(attribution); + } + + public void GetNativeEventSuccess(string eventSuccessData) + { + if (IsEditor()) + { + return; + } + + if (Adjust.eventSuccessDelegate == null) + { + Debug.Log("[Adjust]: Event success delegate was not set."); + return; + } + + var eventSuccess = new AdjustEventSuccess(eventSuccessData); + Adjust.eventSuccessDelegate(eventSuccess); + } + + public void GetNativeEventFailure(string eventFailureData) + { + if (IsEditor()) + { + return; + } + + if (Adjust.eventFailureDelegate == null) + { + Debug.Log("[Adjust]: Event failure delegate was not set."); + return; + } + + var eventFailure = new AdjustEventFailure(eventFailureData); + Adjust.eventFailureDelegate(eventFailure); + } + + public void GetNativeSessionSuccess(string sessionSuccessData) + { + if (IsEditor()) + { + return; + } + + if (Adjust.sessionSuccessDelegate == null) + { + Debug.Log("[Adjust]: Session success delegate was not set."); + return; + } + + var sessionSuccess = new AdjustSessionSuccess(sessionSuccessData); + Adjust.sessionSuccessDelegate(sessionSuccess); + } + + public void GetNativeSessionFailure(string sessionFailureData) + { + if (IsEditor()) + { + return; + } + + if (Adjust.sessionFailureDelegate == null) + { + Debug.Log("[Adjust]: Session failure delegate was not set."); + return; + } + + var sessionFailure = new AdjustSessionFailure(sessionFailureData); + Adjust.sessionFailureDelegate(sessionFailure); + } + + public void GetNativeDeferredDeeplink(string deeplinkURL) + { + if (IsEditor()) + { + return; + } + + if (Adjust.deferredDeeplinkDelegate == null) + { + Debug.Log("[Adjust]: Deferred deeplink delegate was not set."); + return; + } + + Adjust.deferredDeeplinkDelegate(deeplinkURL); + } + + public void GetAuthorizationStatus(string authorizationStatus) + { + if (IsEditor()) + { + return; + } + + if (Adjust.authorizationStatusDelegates == null) + { + Debug.Log("[Adjust]: Authorization status delegates were not set."); + return; + } + + foreach (Action callback in Adjust.authorizationStatusDelegates) + { + callback(Int16.Parse(authorizationStatus)); + } + Adjust.authorizationStatusDelegates.Clear(); + } +#endif + + private static bool IsEditor() + { +#if UNITY_EDITOR + Debug.Log(errorMsgEditor); + return true; +#else + return false; +#endif + } + + public static void SetTestOptions(Dictionary testOptions) + { + if (IsEditor()) + { + return; + } + +#if UNITY_IOS + AdjustiOS.SetTestOptions(testOptions); +#elif UNITY_ANDROID + AdjustAndroid.SetTestOptions(testOptions); +#elif (UNITY_WSA || UNITY_WP8) + AdjustWindows.SetTestOptions(testOptions); +#else + Debug.Log("[Adjust]: Cannot run integration tests. None of the supported platforms selected."); +#endif + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/Adjust.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/Adjust.cs.meta new file mode 100644 index 00000000..08f7cad5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/Adjust.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 525ece82a472e4dea837e1ef938fd15d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAppStoreSubscription.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAppStoreSubscription.cs new file mode 100644 index 00000000..73ec83a8 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAppStoreSubscription.cs @@ -0,0 +1,56 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustAppStoreSubscription + { + internal string price; + internal string currency; + internal string transactionId; + internal string receipt; + internal string billingStore; + internal string transactionDate; + internal string salesRegion; + internal List partnerList; + internal List callbackList; + + public AdjustAppStoreSubscription(string price, string currency, string transactionId, string receipt) + { + this.price = price; + this.currency = currency; + this.transactionId = transactionId; + this.receipt = receipt; + } + + public void setTransactionDate(string transactionDate) + { + this.transactionDate = transactionDate; + } + + public void setSalesRegion(string salesRegion) + { + this.salesRegion = salesRegion; + } + + public void addCallbackParameter(string key, string value) + { + if (callbackList == null) + { + callbackList = new List(); + } + callbackList.Add(key); + callbackList.Add(value); + } + + public void addPartnerParameter(string key, string value) + { + if (partnerList == null) + { + partnerList = new List(); + } + partnerList.Add(key); + partnerList.Add(value); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAppStoreSubscription.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAppStoreSubscription.cs.meta new file mode 100644 index 00000000..f5af3305 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAppStoreSubscription.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7e2d69221b1124370a4c016edce5a95a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAttribution.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAttribution.cs new file mode 100644 index 00000000..5ae59129 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAttribution.cs @@ -0,0 +1,81 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustAttribution + { + public string adid { get; set; } + public string network { get; set; } + public string adgroup { get; set; } + public string campaign { get; set; } + public string creative { get; set; } + public string clickLabel { get; set; } + public string trackerName { get; set; } + public string trackerToken { get; set; } + public string costType { get; set; } + public double? costAmount { get; set; } + public string costCurrency { get; set; } + + public AdjustAttribution() {} + + public AdjustAttribution(string jsonString) + { + var jsonNode = JSON.Parse(jsonString); + if (jsonNode == null) + { + return; + } + + trackerName = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyTrackerName); + trackerToken = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyTrackerToken); + network = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyNetwork); + campaign = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyCampaign); + adgroup = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyAdgroup); + creative = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyCreative); + clickLabel = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyClickLabel); + adid = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyAdid); + costType = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyCostType); + try + { + costAmount = double.Parse(AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyCostAmount), + System.Globalization.CultureInfo.InvariantCulture); + } + catch (Exception) + { + // attribution response doesn't contain cost amount attached + // value will default to null + } + costCurrency = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyCostCurrency); + } + + public AdjustAttribution(Dictionary dicAttributionData) + { + if (dicAttributionData == null) + { + return; + } + + trackerName = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyTrackerName); + trackerToken = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyTrackerToken); + network = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyNetwork); + campaign = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyCampaign); + adgroup = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyAdgroup); + creative = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyCreative); + clickLabel = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyClickLabel); + adid = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyAdid); + costType = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyCostType); + try + { + costAmount = double.Parse(AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyCostAmount), + System.Globalization.CultureInfo.InvariantCulture); + } + catch (Exception) + { + // attribution response doesn't contain cost amount attached + // value will default to null + } + costCurrency = AdjustUtils.TryGetValue(dicAttributionData, AdjustUtils.KeyCostCurrency); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAttribution.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAttribution.cs.meta new file mode 100644 index 00000000..37c4bbd4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustAttribution.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cc46748ad0e664f6d839a4f1a23d9f47 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustConfig.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustConfig.cs new file mode 100644 index 00000000..77b4a1f8 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustConfig.cs @@ -0,0 +1,262 @@ +using System; + +namespace com.adjust.sdk +{ + public class AdjustConfig + { + public const string AdjustUrlStrategyChina = "china"; + public const string AdjustUrlStrategyIndia = "india"; + + public const string AdjustDataResidencyEU = "data-residency-eu"; + + public const string AdjustAdRevenueSourceMopub = "mopub"; + public const string AdjustAdRevenueSourceAdmob = "admob"; + public const string AdjustAdRevenueSourceFbNativeAd = "facebook_native_ad"; + public const string AdjustAdRevenueSourceFbAudienceNetwork = "facebook_audience_network"; + public const string AdjustAdRevenueSourceIronsource = "ironsource"; + public const string AdjustAdRevenueSourceFyber = "fyber"; + public const string AdjustAdRevenueSourceAerserv = "aerserv"; + public const string AdjustAdRevenueSourceAppodeal = "appodeal"; + public const string AdjustAdRevenueSourceAdincube = "adincube"; + public const string AdjustAdRevenueSourceFusePowered = "fusepowered"; + public const string AdjustAdRevenueSourceAddaptr = "addapptr"; + public const string AdjustAdRevenueSourceMillenialMediation = "millennial_mediation"; + public const string AdjustAdRevenueSourceFlurry = "flurry"; + public const string AdjustAdRevenueSourceAdmost = "admost"; + public const string AdjustAdRevenueSourceDeltadna = "deltadna"; + public const string AdjustAdRevenueSourceUpsight = "upsight"; + public const string AdjustAdRevenueSourceUnityads = "unityads"; + public const string AdjustAdRevenueSourceAdtoapp = "adtoapp"; + public const string AdjustAdRevenueSourceTapdaq = "tapdaq"; + + internal string appToken; + internal string sceneName; + internal string userAgent; + internal string defaultTracker; + internal string externalDeviceId; + internal string urlStrategy; + internal long? info1; + internal long? info2; + internal long? info3; + internal long? info4; + internal long? secretId; + internal double? delayStart; + internal bool? isDeviceKnown; + internal bool? sendInBackground; + internal bool? eventBufferingEnabled; + internal bool? allowSuppressLogLevel; + internal bool? needsCost; + internal bool launchDeferredDeeplink; + internal AdjustLogLevel? logLevel; + internal AdjustEnvironment environment; + internal Action deferredDeeplinkDelegate; + internal Action eventSuccessDelegate; + internal Action eventFailureDelegate; + internal Action sessionSuccessDelegate; + internal Action sessionFailureDelegate; + internal Action attributionChangedDelegate; + + // Android specific members + internal bool? readImei; + internal bool? preinstallTrackingEnabled; + internal string processName; + // iOS specific members + internal bool? allowiAdInfoReading; + internal bool? allowAdServicesInfoReading; + internal bool? allowIdfaReading; + internal bool? skAdNetworkHandling; + // Windows specific members + internal Action logDelegate; + + public AdjustConfig(string appToken, AdjustEnvironment environment) + { + this.sceneName = ""; + this.processName = ""; + this.appToken = appToken; + this.environment = environment; + } + + public AdjustConfig(string appToken, AdjustEnvironment environment, bool allowSuppressLogLevel) + { + this.sceneName = ""; + this.processName = ""; + this.appToken = appToken; + this.environment = environment; + this.allowSuppressLogLevel = allowSuppressLogLevel; + } + + public void setLogLevel(AdjustLogLevel logLevel) + { + this.logLevel = logLevel; + } + + public void setDefaultTracker(string defaultTracker) + { + this.defaultTracker = defaultTracker; + } + + public void setExternalDeviceId(string externalDeviceId) + { + this.externalDeviceId = externalDeviceId; + } + + public void setLaunchDeferredDeeplink(bool launchDeferredDeeplink) + { + this.launchDeferredDeeplink = launchDeferredDeeplink; + } + + public void setSendInBackground(bool sendInBackground) + { + this.sendInBackground = sendInBackground; + } + + public void setEventBufferingEnabled(bool eventBufferingEnabled) + { + this.eventBufferingEnabled = eventBufferingEnabled; + } + + public void setNeedsCost(bool needsCost) + { + this.needsCost = needsCost; + } + + public void setDelayStart(double delayStart) + { + this.delayStart = delayStart; + } + + public void setUserAgent(string userAgent) + { + this.userAgent = userAgent; + } + + public void setIsDeviceKnown(bool isDeviceKnown) + { + this.isDeviceKnown = isDeviceKnown; + } + + public void setUrlStrategy(String urlStrategy) + { + this.urlStrategy = urlStrategy; + } + + public void deactivateSKAdNetworkHandling() + { + this.skAdNetworkHandling = true; + } + + public void setDeferredDeeplinkDelegate(Action deferredDeeplinkDelegate, string sceneName = "Adjust") + { + this.deferredDeeplinkDelegate = deferredDeeplinkDelegate; + this.sceneName = sceneName; + } + + public Action getDeferredDeeplinkDelegate() + { + return this.deferredDeeplinkDelegate; + } + + public void setAttributionChangedDelegate(Action attributionChangedDelegate, string sceneName = "Adjust") + { + this.attributionChangedDelegate = attributionChangedDelegate; + this.sceneName = sceneName; + } + + public Action getAttributionChangedDelegate() + { + return this.attributionChangedDelegate; + } + + public void setEventSuccessDelegate(Action eventSuccessDelegate, string sceneName = "Adjust") + { + this.eventSuccessDelegate = eventSuccessDelegate; + this.sceneName = sceneName; + } + + public Action getEventSuccessDelegate() + { + return this.eventSuccessDelegate; + } + + public void setEventFailureDelegate(Action eventFailureDelegate, string sceneName = "Adjust") + { + this.eventFailureDelegate = eventFailureDelegate; + this.sceneName = sceneName; + } + + public Action getEventFailureDelegate() + { + return this.eventFailureDelegate; + } + + public void setSessionSuccessDelegate(Action sessionSuccessDelegate, string sceneName = "Adjust") + { + this.sessionSuccessDelegate = sessionSuccessDelegate; + this.sceneName = sceneName; + } + + public Action getSessionSuccessDelegate() + { + return this.sessionSuccessDelegate; + } + + public void setSessionFailureDelegate(Action sessionFailureDelegate, string sceneName = "Adjust") + { + this.sessionFailureDelegate = sessionFailureDelegate; + this.sceneName = sceneName; + } + + public Action getSessionFailureDelegate() + { + return this.sessionFailureDelegate; + } + + public void setAppSecret(long secretId, long info1, long info2, long info3, long info4) + { + this.secretId = secretId; + this.info1 = info1; + this.info2 = info2; + this.info3 = info3; + this.info4 = info4; + } + + // iOS specific methods. + public void setAllowiAdInfoReading(bool allowiAdInfoReading) + { + this.allowiAdInfoReading = allowiAdInfoReading; + } + + public void setAllowAdServicesInfoReading(bool allowAdServicesInfoReading) + { + this.allowAdServicesInfoReading = allowAdServicesInfoReading; + } + + public void setAllowIdfaReading(bool allowIdfaReading) + { + this.allowIdfaReading = allowIdfaReading; + } + + // Android specific methods. + public void setProcessName(string processName) + { + this.processName = processName; + } + + [Obsolete("This is an obsolete method.")] + public void setReadMobileEquipmentIdentity(bool readMobileEquipmentIdentity) + { + // this.readImei = readMobileEquipmentIdentity; + } + + public void setPreinstallTrackingEnabled(bool preinstallTrackingEnabled) + { + this.preinstallTrackingEnabled = preinstallTrackingEnabled; + } + + // Windows specific methods. + public void setLogDelegate(Action logDelegate) + { + this.logDelegate = logDelegate; + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustConfig.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustConfig.cs.meta new file mode 100644 index 00000000..d98ac077 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustConfig.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 02d4cad14fc094b17afde3b685897e5e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEnvironment.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEnvironment.cs new file mode 100755 index 00000000..777cbfb9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEnvironment.cs @@ -0,0 +1,24 @@ +namespace com.adjust.sdk +{ + public enum AdjustEnvironment + { + Sandbox, + Production + } + + public static class AdjustEnvironmentExtension + { + public static string ToLowercaseString(this AdjustEnvironment adjustEnvironment) + { + switch (adjustEnvironment) + { + case AdjustEnvironment.Sandbox: + return "sandbox"; + case AdjustEnvironment.Production: + return "production"; + default: + return "unknown"; + } + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEnvironment.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEnvironment.cs.meta new file mode 100755 index 00000000..fb472428 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEnvironment.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 633f6fa279b2244fdb999db0441f9aac +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEvent.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEvent.cs new file mode 100755 index 00000000..8c0d802f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEvent.cs @@ -0,0 +1,70 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustEvent + { + internal string currency; + internal string eventToken; + internal string callbackId; + internal string transactionId; + internal double? revenue; + internal List partnerList; + internal List callbackList; + // iOS specific members + internal string receipt; + internal bool isReceiptSet; + + public AdjustEvent(string eventToken) + { + this.eventToken = eventToken; + this.isReceiptSet = false; + } + + public void setRevenue(double amount, string currency) + { + this.revenue = amount; + this.currency = currency; + } + + public void addCallbackParameter(string key, string value) + { + if (callbackList == null) + { + callbackList = new List(); + } + callbackList.Add(key); + callbackList.Add(value); + } + + public void addPartnerParameter(string key, string value) + { + if (partnerList == null) + { + partnerList = new List(); + } + partnerList.Add(key); + partnerList.Add(value); + } + + public void setTransactionId(string transactionId) + { + this.transactionId = transactionId; + } + + public void setCallbackId(string callbackId) + { + this.callbackId = callbackId; + } + + // iOS specific methods + [Obsolete("This is an obsolete method. Please use the adjust purchase SDK for purchase verification (https://github.com/adjust/unity_purchase_sdk)")] + public void setReceipt(string receipt, string transactionId) + { + this.receipt = receipt; + this.transactionId = transactionId; + this.isReceiptSet = true; + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEvent.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEvent.cs.meta new file mode 100755 index 00000000..41ea634b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEvent.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cd89f7713977f497a862f1a1b6f60933 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventFailure.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventFailure.cs new file mode 100755 index 00000000..71d63afc --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventFailure.cs @@ -0,0 +1,92 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustEventFailure + { + public string Adid { get; set; } + public string Message { get; set; } + public string Timestamp { get; set; } + public string EventToken { get; set; } + public string CallbackId { get; set; } + public bool WillRetry { get; set; } + public Dictionary JsonResponse { get; set; } + + public AdjustEventFailure() {} + + public AdjustEventFailure(Dictionary eventFailureDataMap) + { + if (eventFailureDataMap == null) + { + return; + } + + Adid = AdjustUtils.TryGetValue(eventFailureDataMap, AdjustUtils.KeyAdid); + Message = AdjustUtils.TryGetValue(eventFailureDataMap, AdjustUtils.KeyMessage); + Timestamp = AdjustUtils.TryGetValue(eventFailureDataMap, AdjustUtils.KeyTimestamp); + EventToken = AdjustUtils.TryGetValue(eventFailureDataMap, AdjustUtils.KeyEventToken); + CallbackId = AdjustUtils.TryGetValue(eventFailureDataMap, AdjustUtils.KeyCallbackId); + + bool willRetry; + if (bool.TryParse(AdjustUtils.TryGetValue(eventFailureDataMap, AdjustUtils.KeyWillRetry), out willRetry)) + { + WillRetry = willRetry; + } + + string jsonResponseString = AdjustUtils.TryGetValue(eventFailureDataMap, AdjustUtils.KeyJsonResponse); + var jsonResponseNode = JSON.Parse(jsonResponseString); + if (jsonResponseNode != null && jsonResponseNode.AsObject != null) + { + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonResponseNode.AsObject, JsonResponse); + } + } + + public AdjustEventFailure(string jsonString) + { + var jsonNode = JSON.Parse(jsonString); + if (jsonNode == null) + { + return; + } + + Adid = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyAdid); + Message = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyMessage); + Timestamp = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyTimestamp); + EventToken = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyEventToken); + CallbackId = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyCallbackId); + WillRetry = Convert.ToBoolean(AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyWillRetry)); + + var jsonResponseNode = jsonNode[AdjustUtils.KeyJsonResponse]; + if (jsonResponseNode == null) + { + return; + } + if (jsonResponseNode.AsObject == null) + { + return; + } + + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonResponseNode.AsObject, JsonResponse); + } + + public void BuildJsonResponseFromString(string jsonResponseString) + { + var jsonNode = JSON.Parse(jsonResponseString); + if (jsonNode == null) + { + return; + } + + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonNode.AsObject, JsonResponse); + } + + public string GetJsonResponse() + { + return AdjustUtils.GetJsonResponseCompact(JsonResponse); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventFailure.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventFailure.cs.meta new file mode 100755 index 00000000..ee12da97 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventFailure.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: ea86cd4e1c6d0496397920902d0f0b5f +timeCreated: 1458128791 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventSuccess.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventSuccess.cs new file mode 100755 index 00000000..3b152532 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventSuccess.cs @@ -0,0 +1,85 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustEventSuccess + { + public string Adid { get; set; } + public string Message { get; set; } + public string Timestamp { get; set; } + public string EventToken { get; set; } + public string CallbackId { get; set; } + + public Dictionary JsonResponse { get; set; } + + public AdjustEventSuccess() {} + + public AdjustEventSuccess(Dictionary eventSuccessDataMap) + { + if (eventSuccessDataMap == null) + { + return; + } + + Adid = AdjustUtils.TryGetValue(eventSuccessDataMap, AdjustUtils.KeyAdid); + Message = AdjustUtils.TryGetValue(eventSuccessDataMap, AdjustUtils.KeyMessage); + Timestamp = AdjustUtils.TryGetValue(eventSuccessDataMap, AdjustUtils.KeyTimestamp); + EventToken = AdjustUtils.TryGetValue(eventSuccessDataMap, AdjustUtils.KeyEventToken); + CallbackId = AdjustUtils.TryGetValue(eventSuccessDataMap, AdjustUtils.KeyCallbackId); + + string jsonResponseString = AdjustUtils.TryGetValue(eventSuccessDataMap, AdjustUtils.KeyJsonResponse); + var jsonResponseNode = JSON.Parse(jsonResponseString); + if (jsonResponseNode != null && jsonResponseNode.AsObject != null) + { + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonResponseNode.AsObject, JsonResponse); + } + } + + public AdjustEventSuccess(string jsonString) + { + var jsonNode = JSON.Parse(jsonString); + if (jsonNode == null) + { + return; + } + + Adid = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyAdid); + Message = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyMessage); + Timestamp = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyTimestamp); + EventToken = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyEventToken); + CallbackId = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyCallbackId); + + var jsonResponseNode = jsonNode[AdjustUtils.KeyJsonResponse]; + if (jsonResponseNode == null) + { + return; + } + if (jsonResponseNode.AsObject == null) + { + return; + } + + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonResponseNode.AsObject, JsonResponse); + } + + public void BuildJsonResponseFromString(string jsonResponseString) + { + var jsonNode = JSON.Parse(jsonResponseString); + if (jsonNode == null) + { + return; + } + + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonNode.AsObject, JsonResponse); + } + + public string GetJsonResponse() + { + return AdjustUtils.GetJsonResponseCompact(JsonResponse); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventSuccess.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventSuccess.cs.meta new file mode 100755 index 00000000..a750f56f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustEventSuccess.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 1957a0e6e9aa14f0e8adefa2120f1e02 +timeCreated: 1458128791 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustLogLevel.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustLogLevel.cs new file mode 100755 index 00000000..cf614f37 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustLogLevel.cs @@ -0,0 +1,62 @@ +namespace com.adjust.sdk +{ + public enum AdjustLogLevel + { + Verbose = 1, + Debug, + Info, + Warn, + Error, + Assert, + Suppress + } + + public static class AdjustLogLevelExtension + { + public static string ToLowercaseString(this AdjustLogLevel AdjustLogLevel) + { + switch (AdjustLogLevel) + { + case AdjustLogLevel.Verbose: + return "verbose"; + case AdjustLogLevel.Debug: + return "debug"; + case AdjustLogLevel.Info: + return "info"; + case AdjustLogLevel.Warn: + return "warn"; + case AdjustLogLevel.Error: + return "error"; + case AdjustLogLevel.Assert: + return "assert"; + case AdjustLogLevel.Suppress: + return "suppress"; + default: + return "unknown"; + } + } + + public static string ToUppercaseString(this AdjustLogLevel AdjustLogLevel) + { + switch (AdjustLogLevel) + { + case AdjustLogLevel.Verbose: + return "VERBOSE"; + case AdjustLogLevel.Debug: + return "DEBUG"; + case AdjustLogLevel.Info: + return "INFO"; + case AdjustLogLevel.Warn: + return "WARN"; + case AdjustLogLevel.Error: + return "ERROR"; + case AdjustLogLevel.Assert: + return "ASSERT"; + case AdjustLogLevel.Suppress: + return "SUPPRESS"; + default: + return "UNKNOWN"; + } + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustLogLevel.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustLogLevel.cs.meta new file mode 100755 index 00000000..226164e7 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustLogLevel.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 428ab44990df24973902248a9d2b43dd +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustPlayStoreSubscription.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustPlayStoreSubscription.cs new file mode 100644 index 00000000..c86e45cb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustPlayStoreSubscription.cs @@ -0,0 +1,54 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustPlayStoreSubscription + { + internal string price; + internal string currency; + internal string sku; + internal string orderId; + internal string signature; + internal string purchaseToken; + internal string billingStore; + internal string purchaseTime; + internal List partnerList; + internal List callbackList; + + public AdjustPlayStoreSubscription(string price, string currency, string sku, string orderId, string signature, string purchaseToken) + { + this.price = price; + this.currency = currency; + this.sku = sku; + this.orderId = orderId; + this.signature = signature; + this.purchaseToken = purchaseToken; + } + + public void setPurchaseTime(string purchaseTime) + { + this.purchaseTime = purchaseTime; + } + + public void addCallbackParameter(string key, string value) + { + if (callbackList == null) + { + callbackList = new List(); + } + callbackList.Add(key); + callbackList.Add(value); + } + + public void addPartnerParameter(string key, string value) + { + if (partnerList == null) + { + partnerList = new List(); + } + partnerList.Add(key); + partnerList.Add(value); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustPlayStoreSubscription.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustPlayStoreSubscription.cs.meta new file mode 100644 index 00000000..8b827323 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustPlayStoreSubscription.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 69e7a4074abb44758b3f011d8352a57a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionFailure.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionFailure.cs new file mode 100755 index 00000000..6d062865 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionFailure.cs @@ -0,0 +1,86 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustSessionFailure + { + public string Adid { get; set; } + public string Message { get; set; } + public string Timestamp { get; set; } + public bool WillRetry { get; set; } + public Dictionary JsonResponse { get; set; } + + public AdjustSessionFailure() {} + + public AdjustSessionFailure(Dictionary sessionFailureDataMap) + { + if (sessionFailureDataMap == null) + { + return; + } + + Adid = AdjustUtils.TryGetValue(sessionFailureDataMap, AdjustUtils.KeyAdid); + Message = AdjustUtils.TryGetValue(sessionFailureDataMap, AdjustUtils.KeyMessage); + Timestamp = AdjustUtils.TryGetValue(sessionFailureDataMap, AdjustUtils.KeyTimestamp); + + bool willRetry; + if (bool.TryParse(AdjustUtils.TryGetValue(sessionFailureDataMap, AdjustUtils.KeyWillRetry), out willRetry)) + { + WillRetry = willRetry; + } + + string jsonResponseString = AdjustUtils.TryGetValue(sessionFailureDataMap, AdjustUtils.KeyJsonResponse); + var jsonResponseNode = JSON.Parse(jsonResponseString); + if (jsonResponseNode != null && jsonResponseNode.AsObject != null) + { + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonResponseNode.AsObject, JsonResponse); + } + } + + public AdjustSessionFailure(string jsonString) + { + var jsonNode = JSON.Parse(jsonString); + if (jsonNode == null) + { + return; + } + + Adid = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyAdid); + Message = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyMessage); + Timestamp = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyTimestamp); + WillRetry = Convert.ToBoolean(AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyWillRetry)); + + var jsonResponseNode = jsonNode[AdjustUtils.KeyJsonResponse]; + if (jsonResponseNode == null) + { + return; + } + if (jsonResponseNode.AsObject == null) + { + return; + } + + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonResponseNode.AsObject, JsonResponse); + } + + public void BuildJsonResponseFromString(string jsonResponseString) + { + var jsonNode = JSON.Parse(jsonResponseString); + if (jsonNode == null) + { + return; + } + + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonNode.AsObject, JsonResponse); + } + + public string GetJsonResponse() + { + return AdjustUtils.GetJsonResponseCompact(JsonResponse); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionFailure.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionFailure.cs.meta new file mode 100755 index 00000000..4e905a42 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionFailure.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: b4de268ab985448a594fb82264190742 +timeCreated: 1458128791 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionSuccess.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionSuccess.cs new file mode 100755 index 00000000..fd55affe --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionSuccess.cs @@ -0,0 +1,78 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustSessionSuccess + { + public string Adid { get; set; } + public string Message { get; set; } + public string Timestamp { get; set; } + public Dictionary JsonResponse { get; set; } + + public AdjustSessionSuccess() {} + + public AdjustSessionSuccess(Dictionary sessionSuccessDataMap) + { + if (sessionSuccessDataMap == null) + { + return; + } + + Adid = AdjustUtils.TryGetValue(sessionSuccessDataMap, AdjustUtils.KeyAdid); + Message = AdjustUtils.TryGetValue(sessionSuccessDataMap, AdjustUtils.KeyMessage); + Timestamp = AdjustUtils.TryGetValue(sessionSuccessDataMap, AdjustUtils.KeyTimestamp); + + string jsonResponseString = AdjustUtils.TryGetValue(sessionSuccessDataMap, AdjustUtils.KeyJsonResponse); + var jsonResponseNode = JSON.Parse(jsonResponseString); + if (jsonResponseNode != null && jsonResponseNode.AsObject != null) + { + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonResponseNode.AsObject, JsonResponse); + } + } + + public AdjustSessionSuccess(string jsonString) + { + var jsonNode = JSON.Parse(jsonString); + if (jsonNode == null) + { + return; + } + + Adid = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyAdid); + Message = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyMessage); + Timestamp = AdjustUtils.GetJsonString(jsonNode, AdjustUtils.KeyTimestamp); + + var jsonResponseNode = jsonNode[AdjustUtils.KeyJsonResponse]; + if (jsonResponseNode == null) + { + return; + } + if (jsonResponseNode.AsObject == null) + { + return; + } + + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonResponseNode.AsObject, JsonResponse); + } + + public void BuildJsonResponseFromString(string jsonResponseString) + { + var jsonNode = JSON.Parse(jsonResponseString); + if (jsonNode == null) + { + return; + } + + JsonResponse = new Dictionary(); + AdjustUtils.WriteJsonResponseDictionary(jsonNode.AsObject, JsonResponse); + } + + public string GetJsonResponse() + { + return AdjustUtils.GetJsonResponseCompact(JsonResponse); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionSuccess.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionSuccess.cs.meta new file mode 100755 index 00000000..643c0831 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustSessionSuccess.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: c23847e7a1f464d7a8c7f9b35829af17 +timeCreated: 1458128791 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustThirdPartySharing.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustThirdPartySharing.cs new file mode 100644 index 00000000..651e62d2 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustThirdPartySharing.cs @@ -0,0 +1,40 @@ +using System; +using System.Collections.Generic; + +namespace com.adjust.sdk +{ + public class AdjustThirdPartySharing + { + internal bool? isEnabled; + internal Dictionary> granularOptions; + + public AdjustThirdPartySharing(bool? isEnabled) + { + this.isEnabled = isEnabled; + this.granularOptions = new Dictionary>(); + } + + public void addGranularOption(string partnerName, string key, string value) + { + // TODO: consider to add some logs about the error case + if (partnerName == null || key == null || value == null) + { + return; + } + + List partnerOptions; + if (granularOptions.ContainsKey(partnerName)) + { + partnerOptions = granularOptions[partnerName]; + } + else + { + partnerOptions = new List(); + granularOptions.Add(partnerName, partnerOptions); + } + + partnerOptions.Add(key); + partnerOptions.Add(value); + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustThirdPartySharing.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustThirdPartySharing.cs.meta new file mode 100644 index 00000000..5270a0b8 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustThirdPartySharing.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: dcb2591dfab904327904b8879af699ca +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustUtils.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustUtils.cs new file mode 100644 index 00000000..ffe788cb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustUtils.cs @@ -0,0 +1,293 @@ +using System; +using System.Collections.Generic; + +using UnityEngine; + +namespace com.adjust.sdk +{ + public class AdjustUtils + { + public static string KeyAdid = "adid"; + public static string KeyMessage = "message"; + public static string KeyNetwork = "network"; + public static string KeyAdgroup = "adgroup"; + public static string KeyCampaign = "campaign"; + public static string KeyCreative = "creative"; + public static string KeyWillRetry = "willRetry"; + public static string KeyTimestamp = "timestamp"; + public static string KeyCallbackId = "callbackId"; + public static string KeyEventToken = "eventToken"; + public static string KeyClickLabel = "clickLabel"; + public static string KeyTrackerName = "trackerName"; + public static string KeyTrackerToken = "trackerToken"; + public static string KeyJsonResponse = "jsonResponse"; + public static string KeyCostType = "costType"; + public static string KeyCostAmount = "costAmount"; + public static string KeyCostCurrency = "costCurrency"; + + // For testing purposes. + public static string KeyTestOptionsBaseUrl = "baseUrl"; + public static string KeyTestOptionsGdprUrl = "gdprUrl"; + public static string KeyTestOptionsSubscriptionUrl = "subscriptionUrl"; + public static string KeyTestOptionsExtraPath = "extraPath"; + public static string KeyTestOptionsBasePath = "basePath"; + public static string KeyTestOptionsGdprPath = "gdprPath"; + public static string KeyTestOptionsDeleteState = "deleteState"; + public static string KeyTestOptionsUseTestConnectionOptions = "useTestConnectionOptions"; + public static string KeyTestOptionsTimerIntervalInMilliseconds = "timerIntervalInMilliseconds"; + public static string KeyTestOptionsTimerStartInMilliseconds = "timerStartInMilliseconds"; + public static string KeyTestOptionsSessionIntervalInMilliseconds = "sessionIntervalInMilliseconds"; + public static string KeyTestOptionsSubsessionIntervalInMilliseconds = "subsessionIntervalInMilliseconds"; + public static string KeyTestOptionsTeardown = "teardown"; + public static string KeyTestOptionsNoBackoffWait = "noBackoffWait"; + public static string KeyTestOptionsiAdFrameworkEnabled = "iAdFrameworkEnabled"; + public static string KeyTestOptionsAdServicesFrameworkEnabled = "adServicesFrameworkEnabled"; + + public static int ConvertLogLevel(AdjustLogLevel? logLevel) + { + if (logLevel == null) + { + return -1; + } + + return (int)logLevel; + } + + public static int ConvertBool(bool? value) + { + if (value == null) + { + return -1; + } + if (value.Value) + { + return 1; + } + else + { + return 0; + } + } + + public static double ConvertDouble(double? value) + { + if (value == null) + { + return -1; + } + + return (double)value; + } + + public static long ConvertLong(long? value) + { + if (value == null) + { + return -1; + } + + return (long)value; + } + + public static string ConvertListToJson(List list) + { + if (list == null) + { + return null; + } + + var jsonArray = new JSONArray(); + foreach (var listItem in list) + { + jsonArray.Add(new JSONData(listItem)); + } + + return jsonArray.ToString(); + } + + public static string GetJsonResponseCompact(Dictionary dictionary) + { + string logJsonResponse = ""; + + if (dictionary == null) + { + return logJsonResponse; + } + else + { + int preLoopCounter = 0; + logJsonResponse += "{"; + + foreach (KeyValuePair pair in dictionary) + { + String valueString = pair.Value as string; + + if (valueString != null) + { + if (++preLoopCounter > 1) + { + logJsonResponse += ","; + } + + // if the value is another JSON/complex-structure + if (valueString.StartsWith("{") && valueString.EndsWith("}")) + { + logJsonResponse += "\"" + pair.Key + "\"" + ":" + valueString; + } + else + { + logJsonResponse += "\"" + pair.Key + "\"" + ":" + "\"" + valueString + "\""; + } + + continue; + } + + Dictionary valueDictionary = pair.Value as Dictionary; + + if (++preLoopCounter > 1) + { + logJsonResponse += ","; + } + + logJsonResponse += "\"" + pair.Key + "\"" + ":"; + logJsonResponse += GetJsonResponseCompact(valueDictionary); + } + + logJsonResponse += "}"; + } + + return logJsonResponse; + } + + public static String GetJsonString(JSONNode node, string key) + { + if (node == null) + { + return null; + } + + // Access value object and cast it to JSONData. + var nodeValue = node[key] as JSONData; + + if (nodeValue == null) + { + return null; + } + + // https://github.com/adjust/unity_sdk/issues/137 + if (nodeValue == "") + { + return null; + } + + return nodeValue.Value; + } + + public static void WriteJsonResponseDictionary(JSONClass jsonObject, Dictionary output) + { + foreach (KeyValuePair pair in jsonObject) + { + // Try to cast value as a complex object. + var subNode = pair.Value.AsObject; + var key = pair.Key; + + // Value is not a complex object. + if (subNode == null) + { + var value = pair.Value.Value; + output.Add(key, value); + continue; + } + + // Create new dictionary for complex type. + var newSubDictionary = new Dictionary(); + + // Save it in the current dictionary. + output.Add(key, newSubDictionary); + + // Recursive call to fill new dictionary. + WriteJsonResponseDictionary(subNode, newSubDictionary); + } + } + + public static string TryGetValue(Dictionary dictionary, string key) + { + string value; + if (dictionary.TryGetValue(key, out value)) + { + // https://github.com/adjust/unity_sdk/issues/137 + if (value == "") + { + return null; + } + return value; + } + return null; + } + +#if UNITY_ANDROID + public static AndroidJavaObject TestOptionsMap2AndroidJavaObject(Dictionary testOptionsMap, AndroidJavaObject ajoCurrentActivity) + { + AndroidJavaObject ajoTestOptions = new AndroidJavaObject("com.adjust.sdk.AdjustTestOptions"); + ajoTestOptions.Set("baseUrl", testOptionsMap[KeyTestOptionsBaseUrl]); + ajoTestOptions.Set("gdprUrl", testOptionsMap[KeyTestOptionsGdprUrl]); + ajoTestOptions.Set("subscriptionUrl", testOptionsMap[KeyTestOptionsSubscriptionUrl]); + + if (testOptionsMap.ContainsKey(KeyTestOptionsExtraPath) && !string.IsNullOrEmpty(testOptionsMap[KeyTestOptionsExtraPath])) + { + ajoTestOptions.Set("basePath", testOptionsMap[KeyTestOptionsExtraPath]); + ajoTestOptions.Set("gdprPath", testOptionsMap[KeyTestOptionsExtraPath]); + ajoTestOptions.Set("subscriptionPath", testOptionsMap[KeyTestOptionsExtraPath]); + } + if (testOptionsMap.ContainsKey(KeyTestOptionsDeleteState) && ajoCurrentActivity != null) + { + ajoTestOptions.Set("context", ajoCurrentActivity); + } + if (testOptionsMap.ContainsKey(KeyTestOptionsUseTestConnectionOptions)) + { + bool useTestConnectionOptions = testOptionsMap[KeyTestOptionsUseTestConnectionOptions].ToLower() == "true"; + AndroidJavaObject ajoUseTestConnectionOptions = new AndroidJavaObject("java.lang.Boolean", useTestConnectionOptions); + ajoTestOptions.Set("useTestConnectionOptions", ajoUseTestConnectionOptions); + } + if (testOptionsMap.ContainsKey(KeyTestOptionsTimerIntervalInMilliseconds)) + { + var timerIntervalInMilliseconds = long.Parse(testOptionsMap[KeyTestOptionsTimerIntervalInMilliseconds]); + AndroidJavaObject ajoTimerIntervalInMilliseconds = new AndroidJavaObject("java.lang.Long", timerIntervalInMilliseconds); + ajoTestOptions.Set("timerIntervalInMilliseconds", ajoTimerIntervalInMilliseconds); + } + if (testOptionsMap.ContainsKey(KeyTestOptionsTimerStartInMilliseconds)) + { + var timerStartInMilliseconds = long.Parse(testOptionsMap[KeyTestOptionsTimerStartInMilliseconds]); + AndroidJavaObject ajoTimerStartInMilliseconds = new AndroidJavaObject("java.lang.Long", timerStartInMilliseconds); + ajoTestOptions.Set("timerStartInMilliseconds", ajoTimerStartInMilliseconds); + } + if (testOptionsMap.ContainsKey(KeyTestOptionsSessionIntervalInMilliseconds)) + { + var sessionIntervalInMilliseconds = long.Parse(testOptionsMap[KeyTestOptionsSessionIntervalInMilliseconds]); + AndroidJavaObject ajoSessionIntervalInMilliseconds = new AndroidJavaObject("java.lang.Long", sessionIntervalInMilliseconds); + ajoTestOptions.Set("sessionIntervalInMilliseconds", ajoSessionIntervalInMilliseconds); + } + if (testOptionsMap.ContainsKey(KeyTestOptionsSubsessionIntervalInMilliseconds)) + { + var subsessionIntervalInMilliseconds = long.Parse(testOptionsMap[KeyTestOptionsSubsessionIntervalInMilliseconds]); + AndroidJavaObject ajoSubsessionIntervalInMilliseconds = new AndroidJavaObject("java.lang.Long", subsessionIntervalInMilliseconds); + ajoTestOptions.Set("subsessionIntervalInMilliseconds", ajoSubsessionIntervalInMilliseconds); + } + if (testOptionsMap.ContainsKey(KeyTestOptionsTeardown)) + { + bool teardown = testOptionsMap[KeyTestOptionsTeardown].ToLower() == "true"; + AndroidJavaObject ajoTeardown = new AndroidJavaObject("java.lang.Boolean", teardown); + ajoTestOptions.Set("teardown", ajoTeardown); + } + if (testOptionsMap.ContainsKey(KeyTestOptionsNoBackoffWait)) + { + bool noBackoffWait = testOptionsMap[KeyTestOptionsNoBackoffWait].ToLower() == "true"; + AndroidJavaObject ajoNoBackoffWait = new AndroidJavaObject("java.lang.Boolean", noBackoffWait); + ajoTestOptions.Set("noBackoffWait", ajoNoBackoffWait); + } + + return ajoTestOptions; + } +#endif + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustUtils.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustUtils.cs.meta new file mode 100644 index 00000000..5f6f1ad7 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Unity/AdjustUtils.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 98e51a1481cc24ddebf93f61f6c1eb9d +timeCreated: 1458230617 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows.meta new file mode 100644 index 00000000..3a3b7ea3 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 394f8d9ac631849959a15878e4666fd6 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/AdjustWindows.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/AdjustWindows.cs new file mode 100644 index 00000000..330d846b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/AdjustWindows.cs @@ -0,0 +1,340 @@ +#if UNITY_WSA +using System; +using System.Collections; +using System.Collections.Generic; +using System.Reflection; +using UnityEngine; + +#if UNITY_WSA_10_0 +using Win10Interface; +#elif UNITY_WP_8_1 +using Win81Interface; +#elif UNITY_WSA +using WinWsInterface; +#endif + +namespace com.adjust.sdk +{ + public class AdjustWindows + { + private const string sdkPrefix = "unity4.28.0"; + private static bool appLaunched = false; + + public static void Start(AdjustConfig adjustConfig) + { + string logLevelString = null; + string environment = adjustConfig.environment.ToLowercaseString(); + + Action> attributionChangedAction = null; + Action> sessionSuccessChangedAction = null; + Action> sessionFailureChangedAction = null; + Action> eventSuccessChangedAction = null; + Action> eventFailureChangedAction = null; + Func deeplinkResponseFunc = null; + + if (adjustConfig.logLevel.HasValue) + { + logLevelString = adjustConfig.logLevel.Value.ToLowercaseString(); + } + + if (adjustConfig.attributionChangedDelegate != null) + { + attributionChangedAction = (attributionMap) => + { + var attribution = new AdjustAttribution(attributionMap); + adjustConfig.attributionChangedDelegate(attribution); + }; + } + + if (adjustConfig.sessionSuccessDelegate != null) + { + sessionSuccessChangedAction = (sessionMap) => + { + var sessionData = new AdjustSessionSuccess(sessionMap); + adjustConfig.sessionSuccessDelegate(sessionData); + }; + } + + if (adjustConfig.sessionFailureDelegate != null) + { + sessionFailureChangedAction = (sessionMap) => + { + var sessionData = new AdjustSessionFailure(sessionMap); + adjustConfig.sessionFailureDelegate(sessionData); + }; + } + + if (adjustConfig.eventSuccessDelegate != null) + { + eventSuccessChangedAction = (eventMap) => + { + var eventData = new AdjustEventSuccess(eventMap); + adjustConfig.eventSuccessDelegate(eventData); + }; + } + + if (adjustConfig.eventFailureDelegate != null) + { + eventFailureChangedAction = (eventMap) => + { + var eventData = new AdjustEventFailure(eventMap); + adjustConfig.eventFailureDelegate(eventData); + }; + } + + if (adjustConfig.deferredDeeplinkDelegate != null) + { + deeplinkResponseFunc = uri => + { + if (adjustConfig.launchDeferredDeeplink) + { + adjustConfig.deferredDeeplinkDelegate(uri); + } + + return adjustConfig.launchDeferredDeeplink; + }; + } + + bool sendInBackground = false; + if (adjustConfig.sendInBackground.HasValue) + { + sendInBackground = adjustConfig.sendInBackground.Value; + } + + double delayStartSeconds = 0; + if (adjustConfig.delayStart.HasValue) + { + delayStartSeconds = adjustConfig.delayStart.Value; + } + + AdjustConfigDto adjustConfigDto = new AdjustConfigDto { + AppToken = adjustConfig.appToken, + Environment = environment, + SdkPrefix = sdkPrefix, + SendInBackground = sendInBackground, + DelayStart = delayStartSeconds, + UserAgent = adjustConfig.userAgent, + DefaultTracker = adjustConfig.defaultTracker, + EventBufferingEnabled = adjustConfig.eventBufferingEnabled, + LaunchDeferredDeeplink = adjustConfig.launchDeferredDeeplink, + LogLevelString = logLevelString, + LogDelegate = adjustConfig.logDelegate, + ActionAttributionChangedData = attributionChangedAction, + ActionSessionSuccessData = sessionSuccessChangedAction, + ActionSessionFailureData = sessionFailureChangedAction, + ActionEventSuccessData = eventSuccessChangedAction, + ActionEventFailureData = eventFailureChangedAction, + FuncDeeplinkResponseData = deeplinkResponseFunc, + IsDeviceKnown = adjustConfig.isDeviceKnown, + SecretId = adjustConfig.secretId, + Info1 = adjustConfig.info1, + Info2 = adjustConfig.info2, + Info3 = adjustConfig.info3, + Info4 = adjustConfig.info4 + }; + + AdjustWinInterface.ApplicationLaunching(adjustConfigDto); + AdjustWinInterface.ApplicationActivated(); + appLaunched = true; + } + + public static void TrackEvent(AdjustEvent adjustEvent) + { + AdjustWinInterface.TrackEvent( + eventToken: adjustEvent.eventToken, + revenue: adjustEvent.revenue, + currency: adjustEvent.currency, + purchaseId: adjustEvent.transactionId, + callbackId: adjustEvent.callbackId, + callbackList: adjustEvent.callbackList, + partnerList: adjustEvent.partnerList + ); + } + + public static bool IsEnabled() + { + return AdjustWinInterface.IsEnabled(); + } + + public static void OnResume() + { + if (!appLaunched) + { + return; + } + + AdjustWinInterface.ApplicationActivated(); + } + + public static void OnPause() + { + AdjustWinInterface.ApplicationDeactivated(); + } + + public static void SetEnabled(bool enabled) + { + AdjustWinInterface.SetEnabled(enabled); + } + + public static void SetOfflineMode(bool offlineMode) + { + AdjustWinInterface.SetOfflineMode(offlineMode); + } + + public static void SendFirstPackages() + { + AdjustWinInterface.SendFirstPackages(); + } + + public static void SetDeviceToken(string deviceToken) + { + AdjustWinInterface.SetDeviceToken(deviceToken); + } + + public static void AppWillOpenUrl(string url) + { + AdjustWinInterface.AppWillOpenUrl(url); + } + + public static void AddSessionPartnerParameter(string key, string value) + { + AdjustWinInterface.AddSessionPartnerParameter(key, value); + } + + public static void AddSessionCallbackParameter(string key, string value) + { + AdjustWinInterface.AddSessionCallbackParameter(key, value); + } + + public static void RemoveSessionPartnerParameter(string key) + { + AdjustWinInterface.RemoveSessionPartnerParameter(key); + } + + public static void RemoveSessionCallbackParameter(string key) + { + AdjustWinInterface.RemoveSessionCallbackParameter(key); + } + + public static void ResetSessionPartnerParameters() + { + AdjustWinInterface.ResetSessionPartnerParameters(); + } + + public static void ResetSessionCallbackParameters() + { + AdjustWinInterface.ResetSessionCallbackParameters(); + } + + public static string GetAdid() + { + return AdjustWinInterface.GetAdid(); + } + + public static string GetSdkVersion() + { + return sdkPrefix + "@" + AdjustWinInterface.GetSdkVersion(); + } + + public static AdjustAttribution GetAttribution() + { + var attributionMap = AdjustWinInterface.GetAttribution(); + if (attributionMap == null) + { + return new AdjustAttribution(); + } + + return new AdjustAttribution(attributionMap); + } + + public static void GdprForgetMe() + { + AdjustWinInterface.GdprForgetMe(); + } + + public static string GetWinAdId() + { + return AdjustWinInterface.GetWindowsAdId(); + } + + public static void SetTestOptions(Dictionary testOptions) + { + string basePath = testOptions.ContainsKey(AdjustUtils.KeyTestOptionsBasePath) ? + testOptions[AdjustUtils.KeyTestOptionsBasePath] : null; + string gdprPath = testOptions.ContainsKey(AdjustUtils.KeyTestOptionsGdprPath) ? + testOptions[AdjustUtils.KeyTestOptionsGdprPath] : null; + long timerIntervalMls = -1; + long timerStartMls = -1; + long sessionIntMls = -1; + long subsessionIntMls = -1; + bool teardown = false; + bool deleteState = false; + bool noBackoffWait = false; + + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsTimerIntervalInMilliseconds)) + { + timerIntervalMls = long.Parse(testOptions[AdjustUtils.KeyTestOptionsTimerIntervalInMilliseconds]); + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsTimerStartInMilliseconds)) + { + timerStartMls = long.Parse(testOptions[AdjustUtils.KeyTestOptionsTimerStartInMilliseconds]); + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsSessionIntervalInMilliseconds)) + { + sessionIntMls = long.Parse(testOptions[AdjustUtils.KeyTestOptionsSessionIntervalInMilliseconds]); + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsSubsessionIntervalInMilliseconds)) + { + subsessionIntMls = long.Parse(testOptions[AdjustUtils.KeyTestOptionsSubsessionIntervalInMilliseconds]); + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsTeardown)) + { + teardown = testOptions[AdjustUtils.KeyTestOptionsTeardown].ToLower() == "true"; + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsDeleteState)) + { + deleteState = testOptions[AdjustUtils.KeyTestOptionsDeleteState].ToLower() == "true"; + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsNoBackoffWait)) + { + noBackoffWait = testOptions[AdjustUtils.KeyTestOptionsNoBackoffWait].ToLower() == "true"; + } + + Type testLibInterfaceType = Type.GetType("TestLibraryInterface.TestLibraryInterface, TestLibraryInterface"); + Type adjustTestOptionsDtoType = Type.GetType("TestLibraryInterface.AdjustTestOptionsDto, TestLibraryInterface"); + if (testLibInterfaceType == null || adjustTestOptionsDtoType == null) + { + return; + } + + PropertyInfo baseUrlInfo = adjustTestOptionsDtoType.GetProperty("BaseUrl"); + PropertyInfo gdprUrlInfo = adjustTestOptionsDtoType.GetProperty("GdprUrl"); + PropertyInfo basePathInfo = adjustTestOptionsDtoType.GetProperty("BasePath"); + PropertyInfo gdprPathInfo = adjustTestOptionsDtoType.GetProperty("GdprPath"); + PropertyInfo sessionIntervalInMillisecondsInfo = adjustTestOptionsDtoType.GetProperty("SessionIntervalInMilliseconds"); + PropertyInfo subsessionIntervalInMillisecondsInfo = adjustTestOptionsDtoType.GetProperty("SubsessionIntervalInMilliseconds"); + PropertyInfo timerIntervalInMillisecondsInfo = adjustTestOptionsDtoType.GetProperty("TimerIntervalInMilliseconds"); + PropertyInfo timerStartInMillisecondsInfo = adjustTestOptionsDtoType.GetProperty("TimerStartInMilliseconds"); + PropertyInfo deleteStateInfo = adjustTestOptionsDtoType.GetProperty("DeleteState"); + PropertyInfo teardownInfo = adjustTestOptionsDtoType.GetProperty("Teardown"); + PropertyInfo noBackoffWaitInfo = adjustTestOptionsDtoType.GetProperty("NoBackoffWait"); + + object adjustTestOptionsDtoInstance = Activator.CreateInstance(adjustTestOptionsDtoType); + baseUrlInfo.SetValue(adjustTestOptionsDtoInstance, testOptions[AdjustUtils.KeyTestOptionsBaseUrl], null); + gdprUrlInfo.SetValue(adjustTestOptionsDtoInstance, testOptions[AdjustUtils.KeyTestOptionsGdprUrl], null); + basePathInfo.SetValue(adjustTestOptionsDtoInstance, basePath, null); + gdprPathInfo.SetValue(adjustTestOptionsDtoInstance, gdprPath, null); + sessionIntervalInMillisecondsInfo.SetValue(adjustTestOptionsDtoInstance, sessionIntMls, null); + subsessionIntervalInMillisecondsInfo.SetValue(adjustTestOptionsDtoInstance, subsessionIntMls, null); + timerIntervalInMillisecondsInfo.SetValue(adjustTestOptionsDtoInstance, timerIntervalMls, null); + timerStartInMillisecondsInfo.SetValue(adjustTestOptionsDtoInstance, timerStartMls, null); + deleteStateInfo.SetValue(adjustTestOptionsDtoInstance, deleteState, null); + teardownInfo.SetValue(adjustTestOptionsDtoInstance, teardown, null); + noBackoffWaitInfo.SetValue(adjustTestOptionsDtoInstance, noBackoffWait, null); + + MethodInfo setTestOptionsMethodInfo = testLibInterfaceType.GetMethod("SetTestOptions"); + setTestOptionsMethodInfo.Invoke(null, new object[] { adjustTestOptionsDtoInstance }); + } + } +} +#endif diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/AdjustWindows.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/AdjustWindows.cs.meta new file mode 100644 index 00000000..2dba0264 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/AdjustWindows.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 3427d1638e7de554f822f2758d5efa5d +timeCreated: 1510134931 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Newtonsoft.Json.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Newtonsoft.Json.dll new file mode 100644 index 00000000..89bc2b8c Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Newtonsoft.Json.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Newtonsoft.Json.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Newtonsoft.Json.dll.meta new file mode 100644 index 00000000..99f3c9fd --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Newtonsoft.Json.dll.meta @@ -0,0 +1,142 @@ +fileFormatVersion: 2 +guid: dde5cfaaa61544444adb278e3df09051 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + '': Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + - first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: AnySDK + ScriptingBackend: AnyScriptingBackend + - first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + - first: + tvOS: tvOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs.meta new file mode 100644 index 00000000..d6f048de --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4dac6ae00a4af431c8f0144d0c0a28db +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win10Interface.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win10Interface.dll new file mode 100755 index 00000000..3d928338 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win10Interface.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win10Interface.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win10Interface.dll.meta new file mode 100755 index 00000000..21ae70cf --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win10Interface.dll.meta @@ -0,0 +1,142 @@ +fileFormatVersion: 2 +guid: 437f3d4f145f71f48ad0468a8cdd840a +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + '': Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 0 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: AnySDK + ScriptingBackend: AnyScriptingBackend + - first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + - first: + tvOS: tvOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win81Interface.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win81Interface.dll new file mode 100755 index 00000000..3b577e96 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win81Interface.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win81Interface.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win81Interface.dll.meta new file mode 100755 index 00000000..b3c62563 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/Win81Interface.dll.meta @@ -0,0 +1,142 @@ +fileFormatVersion: 2 +guid: 4a3249a2bc5a2fc4b90ec1effe1d74ce +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + '': Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 0 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: AnySDK + ScriptingBackend: AnyScriptingBackend + - first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + - first: + tvOS: tvOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/WinWsInterface.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/WinWsInterface.dll new file mode 100755 index 00000000..610ee9b7 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/WinWsInterface.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/WinWsInterface.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/WinWsInterface.dll.meta new file mode 100755 index 00000000..c9c268b9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/Stubs/WinWsInterface.dll.meta @@ -0,0 +1,142 @@ +fileFormatVersion: 2 +guid: 28d42f4475bd4c9498aea78c129a80b7 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + '': Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 0 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: AnySDK + ScriptingBackend: AnyScriptingBackend + - first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + - first: + tvOS: tvOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81.meta new file mode 100644 index 00000000..d935a0c5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d136d3ff905a449d7a60220941bc37a2 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/AdjustWP81.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/AdjustWP81.dll new file mode 100644 index 00000000..adf479a7 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/AdjustWP81.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/AdjustWP81.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/AdjustWP81.dll.meta new file mode 100644 index 00000000..760c329e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/AdjustWP81.dll.meta @@ -0,0 +1,132 @@ +fileFormatVersion: 2 +guid: 1e03a607fa75e4a488d6d61ca75c352a +timeCreated: 1510575008 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + data: + first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: PhoneSDK81 + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/Win81Interface.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/Win81Interface.dll new file mode 100644 index 00000000..7dc09b4c Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/Win81Interface.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/Win81Interface.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/Win81Interface.dll.meta new file mode 100644 index 00000000..94bba2a5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/W81/Win81Interface.dll.meta @@ -0,0 +1,132 @@ +fileFormatVersion: 2 +guid: 72c922127edd0e94b972c6e40580ec90 +timeCreated: 1510575009 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + data: + first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: Assets/Adjust/Windows/Stubs/Win81Interface.dll + SDK: PhoneSDK81 + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS.meta new file mode 100644 index 00000000..fce0a52e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d62dfd90de0c6477ca80082a36ed4880 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/AdjustWS.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/AdjustWS.dll new file mode 100644 index 00000000..7845be95 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/AdjustWS.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/AdjustWS.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/AdjustWS.dll.meta new file mode 100644 index 00000000..3a8b3b24 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/AdjustWS.dll.meta @@ -0,0 +1,132 @@ +fileFormatVersion: 2 +guid: 244b7bed1ea0ae147b5732f948d3e207 +timeCreated: 1510575008 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + data: + first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: SDK81 + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/WinWsInterface.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/WinWsInterface.dll new file mode 100644 index 00000000..b07e176b Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/WinWsInterface.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/WinWsInterface.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/WinWsInterface.dll.meta new file mode 100644 index 00000000..c8b10890 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WS/WinWsInterface.dll.meta @@ -0,0 +1,132 @@ +fileFormatVersion: 2 +guid: 35b13abbb89b9874d811856667cc3186 +timeCreated: 1510575009 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + data: + first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: Assets/Adjust/Windows/Stubs/WinWsInterface.dll + SDK: SDK81 + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10.meta new file mode 100644 index 00000000..922425b0 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ebdd9874d9b46462e91b519e883b3b92 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/AdjustUAP10.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/AdjustUAP10.dll new file mode 100644 index 00000000..c407a2e0 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/AdjustUAP10.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/AdjustUAP10.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/AdjustUAP10.dll.meta new file mode 100644 index 00000000..eee9c487 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/AdjustUAP10.dll.meta @@ -0,0 +1,146 @@ +fileFormatVersion: 2 +guid: 3b969527d95894f4b8710cce1119c292 +timeCreated: 1509723106 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + data: + first: + Any: + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + Exclude iOS: 1 + Exclude tvOS: 1 + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: UWP + ScriptingBackend: AnyScriptingBackend + data: + first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + data: + first: + tvOS: tvOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/Win10Interface.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/Win10Interface.dll new file mode 100644 index 00000000..4f9a8675 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/Win10Interface.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/Win10Interface.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/Win10Interface.dll.meta new file mode 100644 index 00000000..63690a80 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WU10/Win10Interface.dll.meta @@ -0,0 +1,151 @@ +fileFormatVersion: 2 +guid: 64aebd589aa21cd489368a1570e09acd +timeCreated: 1509723107 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + Exclude iOS: 1 + data: + first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + data: + first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: Assets/Adjust/Windows/Stubs/Win10Interface.dll + SDK: UWP + ScriptingBackend: AnyScriptingBackend + data: + first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsPcl.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsPcl.dll new file mode 100644 index 00000000..0708bc33 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsPcl.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsPcl.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsPcl.dll.meta new file mode 100644 index 00000000..44ff1b14 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsPcl.dll.meta @@ -0,0 +1,132 @@ +fileFormatVersion: 2 +guid: f29a24c7f8821a04b948fa281beaadc0 +timeCreated: 1509723108 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + data: + first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: AnySDK + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsUap.dll b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsUap.dll new file mode 100644 index 00000000..6a1ce938 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsUap.dll differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsUap.dll.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsUap.dll.meta new file mode 100644 index 00000000..4b14581d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/Windows/WindowsUap.dll.meta @@ -0,0 +1,132 @@ +fileFormatVersion: 2 +guid: 50382477c784d8146a4c96803ec33711 +timeCreated: 1509723107 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + data: + first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: + SDK: AnySDK + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS.meta new file mode 100644 index 00000000..d7a4086c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f9b488dae4a044f01a646399132a57a3 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJAttribution.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJAttribution.h new file mode 100644 index 00000000..845a909a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJAttribution.h @@ -0,0 +1,99 @@ +// +// ADJAttribution.h +// adjust +// +// Created by Pedro Filipe on 29/10/14. +// Copyright (c) 2014 adjust GmbH. All rights reserved. +// + +#import + +/** + * @brief Adjust attribution object. + */ +@interface ADJAttribution : NSObject + +/** + * @brief Tracker token. + */ +@property (nonatomic, copy, nullable) NSString *trackerToken; + +/** + * @brief Tracker name. + */ +@property (nonatomic, copy, nullable) NSString *trackerName; + +/** + * @brief Network name. + */ +@property (nonatomic, copy, nullable) NSString *network; + +/** + * @brief Campaign name. + */ +@property (nonatomic, copy, nullable) NSString *campaign; + +/** + * @brief Adgroup name. + */ +@property (nonatomic, copy, nullable) NSString *adgroup; + +/** + * @brief Creative name. + */ +@property (nonatomic, copy, nullable) NSString *creative; + +/** + * @brief Click label content. + */ +@property (nonatomic, copy, nullable) NSString *clickLabel; + +/** + * @brief Adjust identifier value. + */ +@property (nonatomic, copy, nullable) NSString *adid; + +/** + * @brief Cost type. + */ +@property (nonatomic, copy, nullable) NSString *costType; + +/** + * @brief Cost amount. + */ +@property (nonatomic, copy, nullable) NSNumber *costAmount; + +/** + * @brief Cost currency. + */ +@property (nonatomic, copy, nullable) NSString *costCurrency; + +/** + * @brief Make attribution object. + * + * @param jsonDict Dictionary holding attribution key value pairs. + * @param adid Adjust identifier value. + * + * @return Adjust attribution object. + */ ++ (nullable ADJAttribution *)dataWithJsonDict:(nonnull NSDictionary *)jsonDict adid:(nonnull NSString *)adid; + +- (nullable id)initWithJsonDict:(nonnull NSDictionary *)jsonDict adid:(nonnull NSString *)adid; + +/** + * @brief Check if given attribution equals current one. + * + * @param attribution Attribution object to be compared with current one. + * + * @return Boolean indicating whether two attribution objects are the equal. + */ +- (BOOL)isEqualToAttribution:(nonnull ADJAttribution *)attribution; + +/** + * @brief Get attribution value as dictionary. + * + * @return Dictionary containing attribution as key-value pairs. + */ +- (nullable NSDictionary *)dictionary; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJAttribution.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJAttribution.h.meta new file mode 100644 index 00000000..0bded13b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJAttribution.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 7dddf8beb94ee49a7aba11b4e22e059c +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJConfig.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJConfig.h new file mode 100644 index 00000000..b062cf98 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJConfig.h @@ -0,0 +1,259 @@ +// +// ADJConfig.h +// adjust +// +// Created by Pedro Filipe on 30/10/14. +// Copyright (c) 2014 adjust GmbH. All rights reserved. +// + +#import + +#import "ADJLogger.h" +#import "ADJAttribution.h" +#import "ADJEventSuccess.h" +#import "ADJEventFailure.h" +#import "ADJSessionSuccess.h" +#import "ADJSessionFailure.h" + +/** + * @brief Optional delegate that will get informed about tracking results. + */ +@protocol AdjustDelegate + +@optional + +/** + * @brief Optional delegate method that gets called when the attribution information changed. + * + * @param attribution The attribution information. + * + * @note See ADJAttribution for details. + */ +- (void)adjustAttributionChanged:(nullable ADJAttribution *)attribution; + +/** + * @brief Optional delegate method that gets called when an event is tracked with success. + * + * @param eventSuccessResponseData The response information from tracking with success + * + * @note See ADJEventSuccess for details. + */ +- (void)adjustEventTrackingSucceeded:(nullable ADJEventSuccess *)eventSuccessResponseData; + +/** + * @brief Optional delegate method that gets called when an event is tracked with failure. + * + * @param eventFailureResponseData The response information from tracking with failure + * + * @note See ADJEventFailure for details. + */ +- (void)adjustEventTrackingFailed:(nullable ADJEventFailure *)eventFailureResponseData; + +/** + * @brief Optional delegate method that gets called when an session is tracked with success. + * + * @param sessionSuccessResponseData The response information from tracking with success + * + * @note See ADJSessionSuccess for details. + */ +- (void)adjustSessionTrackingSucceeded:(nullable ADJSessionSuccess *)sessionSuccessResponseData; + +/** + * @brief Optional delegate method that gets called when an session is tracked with failure. + * + * @param sessionFailureResponseData The response information from tracking with failure + * + * @note See ADJSessionFailure for details. + */ +- (void)adjustSessionTrackingFailed:(nullable ADJSessionFailure *)sessionFailureResponseData; + +/** + * @brief Optional delegate method that gets called when a deferred deep link is about to be opened by the adjust SDK. + * + * @param deeplink The deep link url that was received by the adjust SDK to be opened. + * + * @return Boolean that indicates whether the deep link should be opened by the adjust SDK or not. + */ +- (BOOL)adjustDeeplinkResponse:(nullable NSURL *)deeplink; + +@end + +/** + * @brief Adjust configuration object class. + */ +@interface ADJConfig : NSObject + +/** + * @brief SDK prefix. + * + * @note Not to be used by users, intended for non-native adjust SDKs only. + */ +@property (nonatomic, copy, nullable) NSString *sdkPrefix; + +/** + * @brief Default tracker to attribute organic installs to (optional). + */ +@property (nonatomic, copy, nullable) NSString *defaultTracker; + +@property (nonatomic, copy, nullable) NSString *externalDeviceId; + +/** + * @brief Adjust app token. + */ +@property (nonatomic, copy, readonly, nonnull) NSString *appToken; + +/** + * @brief Adjust environment variable. + */ +@property (nonatomic, copy, readonly, nonnull) NSString *environment; + +/** + * @brief Change the verbosity of Adjust's logs. + * + * @note You can increase or reduce the amount of logs from Adjust by passing + * one of the following parameters. Use ADJLogLevelSuppress to disable all logging. + * The desired minimum log level (default: info) + * Must be one of the following: + * - ADJLogLevelVerbose (enable all logging) + * - ADJLogLevelDebug (enable more logging) + * - ADJLogLevelInfo (the default) + * - ADJLogLevelWarn (disable info logging) + * - ADJLogLevelError (disable warnings as well) + * - ADJLogLevelAssert (disable errors as well) + * - ADJLogLevelSuppress (suppress all logging) + */ +@property (nonatomic, assign) ADJLogLevel logLevel; + +/** + * @brief Enable event buffering if your app triggers a lot of events. + * When enabled, events get buffered and only get tracked each + * minute. Buffered events are still persisted, of course. + */ +@property (nonatomic, assign) BOOL eventBufferingEnabled; + +/** + * @brief Set the optional delegate that will inform you about attribution or events. + * + * @note See the AdjustDelegate declaration above for details. + */ +@property (nonatomic, weak, nullable) NSObject *delegate; + +/** + * @brief Enables sending in the background. + */ +@property (nonatomic, assign) BOOL sendInBackground; + +/** + * @brief Enables/disables reading of iAd framework data needed for ASA tracking. + */ +@property (nonatomic, assign) BOOL allowiAdInfoReading; + +/** + * @brief Enables/disables reading of AdServices framework data needed for attribution. + */ +@property (nonatomic, assign) BOOL allowAdServicesInfoReading; + +/** + * @brief Enables/disables reading of IDFA parameter. + */ +@property (nonatomic, assign) BOOL allowIdfaReading; + +/** + * @brief Enables delayed start of the SDK. + */ +@property (nonatomic, assign) double delayStart; + +/** + * @brief User agent for the requests. + */ +@property (nonatomic, copy, nullable) NSString *userAgent; + +/** + * @brief Set if the device is known. + */ +@property (nonatomic, assign) BOOL isDeviceKnown; + +/** + * @brief Set if cost data is needed in attribution response. + */ +@property (nonatomic, assign) BOOL needsCost; + +/** + * @brief Adjust app secret id. + */ +@property (nonatomic, copy, readonly, nullable) NSString *secretId; + +/** + * @brief Adjust app secret. + */ +@property (nonatomic, copy, readonly, nullable) NSString *appSecret; + +/** + * @brief Adjust set app secret. + */ +- (void)setAppSecret:(NSUInteger)secretId + info1:(NSUInteger)info1 + info2:(NSUInteger)info2 + info3:(NSUInteger)info3 + info4:(NSUInteger)info4; + + +@property (nonatomic, assign, readonly) BOOL isSKAdNetworkHandlingActive; + +- (void)deactivateSKAdNetworkHandling; + +/** + * @brief Adjust url strategy. + */ +@property (nonatomic, copy, readwrite, nullable) NSString *urlStrategy; + +/** + * @brief Get configuration object for the initialization of the Adjust SDK. + * + * @param appToken The App Token of your app. This unique identifier can + * be found it in your dashboard at http://adjust.com and should always + * be 12 characters long. + * @param environment The current environment your app. We use this environment to + * distinguish between real traffic and artificial traffic from test devices. + * It is very important that you keep this value meaningful at all times! + * Especially if you are tracking revenue. + * + * @returns Adjust configuration object. + */ ++ (nullable ADJConfig *)configWithAppToken:(nonnull NSString *)appToken + environment:(nonnull NSString *)environment; + +- (nullable id)initWithAppToken:(nonnull NSString *)appToken + environment:(nonnull NSString *)environment; + +/** + * @brief Configuration object for the initialization of the Adjust SDK. + * + * @param appToken The App Token of your app. This unique identifier can + * be found it in your dashboard at http://adjust.com and should always + * be 12 characters long. + * @param environment The current environment your app. We use this environment to + * distinguish between real traffic and artificial traffic from test devices. + * It is very important that you keep this value meaningful at all times! + * Especially if you are tracking revenue. + * @param allowSuppressLogLevel If set to true, it allows usage of ADJLogLevelSuppress + * and replaces the default value for production environment. + * + * @returns Adjust configuration object. + */ ++ (nullable ADJConfig *)configWithAppToken:(nonnull NSString *)appToken + environment:(nonnull NSString *)environment + allowSuppressLogLevel:(BOOL)allowSuppressLogLevel; + +- (nullable id)initWithAppToken:(nonnull NSString *)appToken + environment:(nonnull NSString *)environment + allowSuppressLogLevel:(BOOL)allowSuppressLogLevel; + +/** + * @brief Check if adjust configuration object is valid. + * + * @return Boolean indicating whether adjust config object is valid or not. + */ +- (BOOL)isValid; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJConfig.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJConfig.h.meta new file mode 100644 index 00000000..92c48f2a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJConfig.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 0c958f3cabffd44b6a58b8e0621ee82e +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEvent.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEvent.h new file mode 100644 index 00000000..a2363c22 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEvent.h @@ -0,0 +1,140 @@ +// +// ADJEvent.h +// adjust +// +// Created by Pedro Filipe on 15/10/14. +// Copyright (c) 2014 adjust GmbH. All rights reserved. +// + +#import + +/** + * @brief Adjust event class. + */ +@interface ADJEvent : NSObject + +/** + * @brief Revenue attached to the event. + */ +@property (nonatomic, copy, readonly, nonnull) NSNumber *revenue; + +/** + * @brief Event token. + */ +@property (nonatomic, copy, readonly, nonnull) NSString *eventToken; + +/** + * @brief IAP transaction ID. + */ +@property (nonatomic, copy, readonly, nonnull) NSString *transactionId; + +/** + * @brief Custom user defined event ID. + */ +@property (nonatomic, copy, readonly, nonnull) NSString *callbackId; + +/** + * @brief Currency value. + */ +@property (nonatomic, copy, readonly, nonnull) NSString *currency; + +/** + * @brief IAP receipt. + */ +@property (nonatomic, copy, readonly, nonnull) NSData *receipt; + +/** + * @brief List of partner parameters. + */ +@property (nonatomic, readonly, nonnull) NSDictionary *partnerParameters; + +/** + * @brief List of callback parameters. + */ +@property (nonatomic, readonly, nonnull) NSDictionary *callbackParameters; + +/** + * @brief Is the given receipt empty. + */ +@property (nonatomic, assign, readonly) BOOL emptyReceipt; + +/** + * @brief Create Event object with event token. + * + * @param eventToken Event token that is created in the dashboard + * at http://adjust.com and should be six characters long. + */ ++ (nullable ADJEvent *)eventWithEventToken:(nonnull NSString *)eventToken; + +- (nullable id)initWithEventToken:(nonnull NSString *)eventToken; + +/** + * @brief Add a key-pair to a callback URL. + * + * @param key String key in the callback URL. + * @param value String value of the key in the Callback URL. + * + * @note In your dashboard at http://adjust.com you can assign a callback URL to each + * event type. That URL will get called every time the event is triggered. On + * top of that you can add callback parameters to the following method that + * will be forwarded to these callbacks. + */ +- (void)addCallbackParameter:(nonnull NSString *)key value:(nonnull NSString *)value; + +/** + * @brief Add a key-pair to be fowarded to a partner. + * + * @param key String key to be fowarded to the partner. + * @param value String value of the key to be fowarded to the partner. + */ +- (void)addPartnerParameter:(nonnull NSString *)key value:(nonnull NSString *)value; + +/** + * @brief Set the revenue and associated currency of the event. + * + * @param amount The amount in units (example: for 1.50 EUR is 1.5). + * @param currency String of the currency with ISO 4217 format. + * It should be 3 characters long (example: for 1.50 EUR is @"EUR"). + * + * @note The event can contain some revenue. The amount revenue is measured in units. + * It must include a currency in the ISO 4217 format. + */ +- (void)setRevenue:(double)amount currency:(nonnull NSString *)currency; + +/** + * @brief Set the transaction ID of a In-App Purchases to avoid revenue duplications. + * + * @note A transaction ID can be used to avoid duplicate revenue events. The last ten + * transaction identifiers are remembered. + * + * @param transactionId The identifier used to avoid duplicate revenue events. + */ +- (void)setTransactionId:(nonnull NSString *)transactionId; + +/** + * @brief Set the custom user defined ID for the event which will be reported in + * success/failure callbacks. + * + * @param callbackId Custom user defined identifier for the event + */ +- (void)setCallbackId:(nonnull NSString *)callbackId; + +/** + * @brief Check if created adjust event object is valid. + * + * @return Boolean indicating whether the adjust event object is valid or not. + */ +- (BOOL)isValid; + +/** + * @brief Validate a in-app-purchase receipt. + * + * @param receipt The receipt to validate. + * @param transactionId The identifier used to validate the receipt and to avoid duplicate revenue events. + * + * @note This method is obsolete and should not be used. + * For more information, visit: https://github.com/adjust/ios_purchase_sdk + */ +- (void)setReceipt:(nonnull NSData *)receipt transactionId:(nonnull NSString *)transactionId; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEvent.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEvent.h.meta new file mode 100644 index 00000000..9d223072 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEvent.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 426362cccd2154c908b504e138832851 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventFailure.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventFailure.h new file mode 100644 index 00000000..ff272bbc --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventFailure.h @@ -0,0 +1,55 @@ +// +// ADJEventFailure.h +// adjust +// +// Created by Pedro Filipe on 17/02/16. +// Copyright © 2016 adjust GmbH. All rights reserved. +// + +#import + +@interface ADJEventFailure : NSObject + +/** + * @brief Message from the adjust backend. + */ +@property (nonatomic, copy) NSString * message; + +/** + * @brief Timestamp from the adjust backend. + */ +@property (nonatomic, copy) NSString * timeStamp; + +/** + * @brief Adjust identifier of the device. + */ +@property (nonatomic, copy) NSString * adid; + +/** + * @brief Event token value. + */ +@property (nonatomic, copy) NSString * eventToken; + +/** + * @brief Event callback ID. + */ +@property (nonatomic, copy) NSString *callbackId; + +/** + * @brief Information whether sending of the package will be retried or not. + */ +@property (nonatomic, assign) BOOL willRetry; + +/** + * @brief Backend response in JSON format. + */ +@property (nonatomic, strong) NSDictionary *jsonResponse; + +/** + * @brief Initialisation method. + * + * @return ADJEventFailure instance. + */ ++ (ADJEventFailure *)eventFailureResponseData; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventFailure.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventFailure.h.meta new file mode 100644 index 00000000..b54cf126 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventFailure.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: b274a5403f60c4e7ca731709d03d1ee8 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventSuccess.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventSuccess.h new file mode 100644 index 00000000..34214e21 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventSuccess.h @@ -0,0 +1,50 @@ +// +// ADJEventSuccess.h +// adjust +// +// Created by Pedro Filipe on 17/02/16. +// Copyright © 2016 adjust GmbH. All rights reserved. +// + +#import + +@interface ADJEventSuccess : NSObject + +/** + * @brief Message from the adjust backend. + */ +@property (nonatomic, copy) NSString *message; + +/** + * @brief Timestamp from the adjust backend. + */ +@property (nonatomic, copy) NSString *timeStamp; + +/** + * @brief Adjust identifier of the device. + */ +@property (nonatomic, copy) NSString *adid; + +/** + * @brief Event token value. + */ +@property (nonatomic, copy) NSString *eventToken; + +/** + * @brief Event callback ID. + */ +@property (nonatomic, copy) NSString *callbackId; + +/** + * @brief Backend response in JSON format. + */ +@property (nonatomic, strong) NSDictionary *jsonResponse; + +/** + * @brief Initialisation method. + * + * @return ADJEventSuccess instance. + */ ++ (ADJEventSuccess *)eventSuccessResponseData; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventSuccess.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventSuccess.h.meta new file mode 100644 index 00000000..3ed0f961 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJEventSuccess.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 65ff11a24f3b043759b70623a745a004 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJLogger.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJLogger.h new file mode 100644 index 00000000..95bb7433 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJLogger.h @@ -0,0 +1,84 @@ +// +// ADJLogger.h +// Adjust +// +// Created by Christian Wellenbrock on 2012-11-15. +// Copyright (c) 2012-2014 adjust GmbH. All rights reserved. +// +#import + +typedef enum { + ADJLogLevelVerbose = 1, + ADJLogLevelDebug = 2, + ADJLogLevelInfo = 3, + ADJLogLevelWarn = 4, + ADJLogLevelError = 5, + ADJLogLevelAssert = 6, + ADJLogLevelSuppress = 7 +} ADJLogLevel; + +/** + * @brief Adjust logger protocol. + */ +@protocol ADJLogger + +/** + * @brief Set the log level of the SDK. + * + * @param logLevel Level of the logs to be displayed. + */ +- (void)setLogLevel:(ADJLogLevel)logLevel isProductionEnvironment:(BOOL)isProductionEnvironment; + +/** + * @brief Prevent log level changes. + */ +- (void)lockLogLevel; + +/** + * @brief Print verbose logs. + */ +- (void)verbose:(nonnull NSString *)message, ...; + +/** + * @brief Print debug logs. + */ +- (void)debug:(nonnull NSString *)message, ...; + +/** + * @brief Print info logs. + */ +- (void)info:(nonnull NSString *)message, ...; + +/** + * @brief Print warn logs. + */ +- (void)warn:(nonnull NSString *)message, ...; +- (void)warnInProduction:(nonnull NSString *)message, ...; + +/** + * @brief Print error logs. + */ +- (void)error:(nonnull NSString *)message, ...; + +/** + * @brief Print assert logs. + */ +- (void)assert:(nonnull NSString *)message, ...; + +@end + +/** + * @brief Adjust logger class. + */ +@interface ADJLogger : NSObject + +/** + * @brief Convert log level string to ADJLogLevel enumeration. + * + * @param logLevelString Log level as string. + * + * @return Log level as ADJLogLevel enumeration. + */ ++ (ADJLogLevel)logLevelFromString:(nonnull NSString *)logLevelString; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJLogger.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJLogger.h.meta new file mode 100644 index 00000000..e619c96c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJLogger.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 79bead718d24d4562b045c8fb25619ab +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionFailure.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionFailure.h new file mode 100644 index 00000000..2ad9f207 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionFailure.h @@ -0,0 +1,45 @@ +// +// ADJFailureResponseData.h +// adjust +// +// Created by Pedro Filipe on 05/01/16. +// Copyright © 2016 adjust GmbH. All rights reserved. +// + +#import + +@interface ADJSessionFailure : NSObject + +/** + * @brief Message from the adjust backend. + */ +@property (nonatomic, copy, nullable) NSString *message; + +/** + * @brief Timestamp from the adjust backend. + */ +@property (nonatomic, copy, nullable) NSString *timeStamp; + +/** + * @brief Adjust identifier of the device. + */ +@property (nonatomic, copy, nullable) NSString *adid; + +/** + * @brief Information whether sending of the package will be retried or not. + */ +@property (nonatomic, assign) BOOL willRetry; + +/** + * @brief Backend response in JSON format. + */ +@property (nonatomic, strong, nullable) NSDictionary *jsonResponse; + +/** + * @brief Initialisation method. + * + * @return ADJSessionFailure instance. + */ ++ (nullable ADJSessionFailure *)sessionFailureResponseData; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionFailure.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionFailure.h.meta new file mode 100644 index 00000000..76b7a36f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionFailure.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: cb5e6ddbbcae24783900c75db92ead71 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionSuccess.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionSuccess.h new file mode 100644 index 00000000..8d6a04cf --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionSuccess.h @@ -0,0 +1,40 @@ +// +// ADJSuccessResponseData.h +// adjust +// +// Created by Pedro Filipe on 05/01/16. +// Copyright © 2016 adjust GmbH. All rights reserved. +// + +#import + +@interface ADJSessionSuccess : NSObject + +/** + * @brief Message from the adjust backend. + */ +@property (nonatomic, copy, nullable) NSString *message; + +/** + * @brief Timestamp from the adjust backend. + */ +@property (nonatomic, copy, nullable) NSString *timeStamp; + +/** + * @brief Adjust identifier of the device. + */ +@property (nonatomic, copy, nullable) NSString *adid; + +/** + * @brief Backend response in JSON format. + */ +@property (nonatomic, strong, nullable) NSDictionary *jsonResponse; + +/** + * @brief Initialisation method. + * + * @return ADJSessionSuccess instance. + */ ++ (nullable ADJSessionSuccess *)sessionSuccessResponseData; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionSuccess.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionSuccess.h.meta new file mode 100644 index 00000000..b0dfb703 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSessionSuccess.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 65455f64c4f194d6fb1e959ad638f311 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSubscription.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSubscription.h new file mode 100644 index 00000000..92f5395e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSubscription.h @@ -0,0 +1,44 @@ +// +// ADJSubscription.h +// Adjust +// +// Created by Uglješa Erceg on 16.04.20. +// Copyright © 2020 adjust GmbH. All rights reserved. +// + +#import + +@interface ADJSubscription : NSObject + +@property (nonatomic, copy, readonly, nonnull) NSDecimalNumber *price; // [M] revenue + +@property (nonatomic, copy, readonly, nonnull) NSString *currency; // [M] currency + +@property (nonatomic, copy, readonly, nonnull) NSString *transactionId; // [M] transaction_id + +@property (nonatomic, copy, readonly, nonnull) NSData *receipt; // [M] receipt + +@property (nonatomic, copy, readonly, nonnull) NSString *billingStore; // [M] billing_store + +@property (nonatomic, copy, readonly, nonnull) NSDate *transactionDate; // [O] transaction_date + +@property (nonatomic, copy, readonly, nonnull) NSString *salesRegion; // [O] sales_region + +@property (nonatomic, copy, readonly, nonnull) NSDictionary *callbackParameters; // [O] callback_params + +@property (nonatomic, copy, readonly, nonnull) NSDictionary *partnerParameters; // [O] partner_params + +- (nullable id)initWithPrice:(nonnull NSDecimalNumber *)price + currency:(nonnull NSString *)currency + transactionId:(nonnull NSString *)transactionId + andReceipt:(nonnull NSData *)receipt; + +- (void)setTransactionDate:(nonnull NSDate *)transactionDate; + +- (void)setSalesRegion:(nonnull NSString *)salesRegion; + +- (void)addCallbackParameter:(nonnull NSString *)key value:(nonnull NSString *)value; + +- (void)addPartnerParameter:(nonnull NSString *)key value:(nonnull NSString *)value; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSubscription.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSubscription.h.meta new file mode 100644 index 00000000..9c4f0931 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJSubscription.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 15bc7056a22f34382aea2497343c3509 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJThirdPartySharing.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJThirdPartySharing.h new file mode 100644 index 00000000..610ca80b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJThirdPartySharing.h @@ -0,0 +1,23 @@ +// +// ADJThirdPartySharing.h +// AdjustSdk +// +// Created by Pedro S. on 02.12.20. +// Copyright © 2020 adjust GmbH. All rights reserved. +// + +#import + +@interface ADJThirdPartySharing : NSObject + +- (nullable id)initWithIsEnabledNumberBool:(nullable NSNumber *)isEnabledNumberBool; + +- (void)addGranularOption:(nonnull NSString *)partnerName + key:(nonnull NSString *)key + value:(nonnull NSString *)value; + +@property (nonatomic, nullable, readonly, strong) NSNumber *enabled; +@property (nonatomic, nonnull, readonly, strong) NSMutableDictionary *granularOptions; + +@end + diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJThirdPartySharing.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJThirdPartySharing.h.meta new file mode 100644 index 00000000..f9ebea73 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/ADJThirdPartySharing.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: e34005ea3283c4e88bf3dc78e9e845e4 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/Adjust.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/Adjust.h new file mode 100644 index 00000000..efe4dee1 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/Adjust.h @@ -0,0 +1,362 @@ +// +// Adjust.h +// Adjust +// +// V4.28.0 +// Created by Christian Wellenbrock (wellle) on 23rd July 2013. +// Copyright © 2012-2017 Adjust GmbH. All rights reserved. +// + +#import "ADJEvent.h" +#import "ADJConfig.h" +#import "ADJAttribution.h" +#import "ADJSubscription.h" +#import "ADJThirdPartySharing.h" + +@interface AdjustTestOptions : NSObject + +@property (nonatomic, copy, nullable) NSString *baseUrl; +@property (nonatomic, copy, nullable) NSString *gdprUrl; +@property (nonatomic, copy, nullable) NSString *subscriptionUrl; +@property (nonatomic, copy, nullable) NSString *extraPath; +@property (nonatomic, copy, nullable) NSNumber *timerIntervalInMilliseconds; +@property (nonatomic, copy, nullable) NSNumber *timerStartInMilliseconds; +@property (nonatomic, copy, nullable) NSNumber *sessionIntervalInMilliseconds; +@property (nonatomic, copy, nullable) NSNumber *subsessionIntervalInMilliseconds; +@property (nonatomic, assign) BOOL teardown; +@property (nonatomic, assign) BOOL deleteState; +@property (nonatomic, assign) BOOL noBackoffWait; +@property (nonatomic, assign) BOOL iAdFrameworkEnabled; +@property (nonatomic, assign) BOOL adServicesFrameworkEnabled; +@property (nonatomic, assign) BOOL enableSigning; +@property (nonatomic, assign) BOOL disableSigning; + +@end + +/** + * Constants for our supported tracking environments + */ +extern NSString * __nonnull const ADJEnvironmentSandbox; +extern NSString * __nonnull const ADJEnvironmentProduction; + +/** + * Constants for supported ad revenue sources. + */ +extern NSString * __nonnull const ADJAdRevenueSourceMopub; +extern NSString * __nonnull const ADJAdRevenueSourceAdmob; +extern NSString * __nonnull const ADJAdRevenueSourceFbNativeAd; +extern NSString * __nonnull const ADJAdRevenueSourceFbAudienceNetwork; +extern NSString * __nonnull const ADJAdRevenueSourceIronsource; +extern NSString * __nonnull const ADJAdRevenueSourceFyber; +extern NSString * __nonnull const ADJAdRevenueSourceAerserv; +extern NSString * __nonnull const ADJAdRevenueSourceAppodeal; +extern NSString * __nonnull const ADJAdRevenueSourceAdincube; +extern NSString * __nonnull const ADJAdRevenueSourceFusePowered; +extern NSString * __nonnull const ADJAdRevenueSourceAddaptr; +extern NSString * __nonnull const ADJAdRevenueSourceMillennialMeditation; +extern NSString * __nonnull const ADJAdRevenueSourceFlurry; +extern NSString * __nonnull const ADJAdRevenueSourceAdmost; +extern NSString * __nonnull const ADJAdRevenueSourceDeltadna; +extern NSString * __nonnull const ADJAdRevenueSourceUpsight; +extern NSString * __nonnull const ADJAdRevenueSourceUnityads; +extern NSString * __nonnull const ADJAdRevenueSourceAdtoapp; +extern NSString * __nonnull const ADJAdRevenueSourceTapdaq; + +/** + * Constants for country apps url strategies. + */ +extern NSString * __nonnull const ADJUrlStrategyIndia; +extern NSString * __nonnull const ADJUrlStrategyChina; +extern NSString * __nonnull const ADJDataResidencyEU; + +/** + * @brief The main interface to Adjust. + * + * @note Use the methods of this class to tell Adjust about the usage of your app. + * See the README for details. + */ +@interface Adjust : NSObject + +/** + * @brief Tell Adjust that the application did launch. + * This is required to initialize Adjust. Call this in the didFinishLaunching + * method of your AppDelegate. + * + * @note See ADJConfig.h for more configuration options + * + * @param adjustConfig The configuration object that includes the environment + * and the App Token of your app. This unique identifier can + * be found it in your dashboard at http://adjust.com and should always + * be 12 characters long. + */ ++ (void)appDidLaunch:(nullable ADJConfig *)adjustConfig; + +/** + * @brief Tell Adjust that a particular event has happened. + * + * @note See ADJEvent.h for more event options. + * + * @param event The Event object for this kind of event. It needs a event token + * that is created in the dashboard at http://adjust.com and should be six + * characters long. + */ ++ (void)trackEvent:(nullable ADJEvent *)event; + +/** + * @brief Tell adjust that the application resumed. + * + * @note Only necessary if the native notifications can't be used + * or if they will happen before call to appDidLaunch: is made. + */ ++ (void)trackSubsessionStart; + +/** + * @brief Tell adjust that the application paused. + * + * @note Only necessary if the native notifications can't be used. + */ ++ (void)trackSubsessionEnd; + +/** + * @brief Enable or disable the adjust SDK. This setting is saved for future sessions. + * + * @param enabled The flag to enable or disable the adjust SDK. + */ ++ (void)setEnabled:(BOOL)enabled; + +/** + * @brief Check if the SDK is enabled or disabled. + * + * return Boolean indicating whether SDK is enabled or not. + */ ++ (BOOL)isEnabled; + +/** + * @brief Read the URL that opened the application to search for an adjust deep link. + * + * @param url URL object which contains info about adjust deep link. + */ ++ (void)appWillOpenUrl:(nonnull NSURL *)url; + +/** + * @brief Set the device token used by push notifications. + * + * @param deviceToken Apple push notification token for iOS device as NSData. + */ ++ (void)setDeviceToken:(nonnull NSData *)deviceToken; + +/** + * @brief Set the device token used by push notifications. + * This method is only used by Adjust non native SDKs. Don't use it anywhere else. + * + * @param pushToken Apple push notification token for iOS device as NSString. + */ ++ (void)setPushToken:(nonnull NSString *)pushToken; + +/** + * @brief Enable or disable offline mode. Activities won't be sent but they are saved when + * offline mode is disabled. This feature is not saved for future sessions. + * + * @param enabled The flag to enable or disable offline mode. + */ ++ (void)setOfflineMode:(BOOL)enabled; + +/** + * @brief Retrieve iOS device IDFA value. + * + * @return Device IDFA value. + */ ++ (nullable NSString *)idfa; + +/** + * @brief Get current adjust identifier for the user. + * + * @note Adjust identifier is available only after installation has been successfully tracked. + * + * @return Current adjust identifier value for the user. + */ ++ (nullable NSString *)adid; + +/** + * @brief Get current attribution for the user. + * + * @note Attribution information is available only after installation has been successfully tracked + * and attribution information arrived after that from the backend. + * + * @return Current attribution value for the user. + */ ++ (nullable ADJAttribution *)attribution; + +/** + * @brief Get current Adjust SDK version string. + * + * @return Adjust SDK version string (iosX.Y.Z). + */ ++ (nullable NSString *)sdkVersion; + +/** + * @brief Convert a universal link style URL to a deeplink style URL with the corresponding scheme. + * + * @param url URL object which contains info about adjust deep link. + * @param scheme Desired scheme to which you want your resulting URL object to be prefixed with. + * + * @return URL object in custom URL scheme style prefixed with given scheme name. + */ ++ (nullable NSURL *)convertUniversalLink:(nonnull NSURL *)url scheme:(nonnull NSString *)scheme; + +/** + * @brief Tell the adjust SDK to stop waiting for delayed initialisation timer to complete but rather to start + * upon this call. This should be called if you have obtained needed callback/partner parameters which you + * wanted to put as default ones before the delayedStart value you have set on ADJConfig has expired. + */ ++ (void)sendFirstPackages; + +/** + * @brief Tell adjust to send the request to Google and check if the installation + * belongs to Google AdWords campaign. + * + * @note Deprecated method, should not be used. + */ ++ (void)sendAdWordsRequest; + +/** + * @brief Add default callback parameter key-value pair which is going to be sent with each tracked session and event. + * + * @param key Default callback parameter key. + * @param value Default callback parameter value. + */ ++ (void)addSessionCallbackParameter:(nonnull NSString *)key value:(nonnull NSString *)value; + +/** + * @brief Add default partner parameter key-value pair which is going to be sent with each tracked session. + * + * @param key Default partner parameter key. + * @param value Default partner parameter value. + */ ++ (void)addSessionPartnerParameter:(nonnull NSString *)key value:(nonnull NSString *)value; + +/** + * @brief Remove default callback parameter from the session packages. + * + * @param key Default callback parameter key. + */ ++ (void)removeSessionCallbackParameter:(nonnull NSString *)key; + +/** + * @brief Remove default partner parameter from the session packages. + * + * @param key Default partner parameter key. + */ ++ (void)removeSessionPartnerParameter:(nonnull NSString *)key; + +/** + * @brief Remove all default callback parameters from the session packages. + */ ++ (void)resetSessionCallbackParameters; + +/** + * @brief Remove all default partner parameters from the session packages. + */ ++ (void)resetSessionPartnerParameters; + +/** + * @brief Give right user to be forgotten in accordance with GDPR law. + */ ++ (void)gdprForgetMe; + +/** + * @brief Track ad revenue for given source. + * + * @param source Ad revenue source. + * @param payload Ad revenue payload. + */ ++ (void)trackAdRevenue:(nonnull NSString *)source payload:(nonnull NSData *)payload; + +/** + * @brief Give right user to disable sharing data to any third-party. + */ ++ (void)disableThirdPartySharing; + ++ (void)trackThirdPartySharing:(nonnull ADJThirdPartySharing *)thirdPartySharing; + ++ (void)trackMeasurementConsent:(BOOL)enabled; + +/** + * @brief Track subscription. + * + * @param subscription Subscription object. + */ ++ (void)trackSubscription:(nonnull ADJSubscription *)subscription; + ++ (void)requestTrackingAuthorizationWithCompletionHandler:(void (^_Nullable)(NSUInteger status))completion; + ++ (int)appTrackingAuthorizationStatus; + ++ (void)updateConversionValue:(NSInteger)conversionValue; + +/** + * Obtain singleton Adjust object. + */ ++ (nullable id)getInstance; + ++ (void)setTestOptions:(nullable AdjustTestOptions *)testOptions; + +- (void)appDidLaunch:(nullable ADJConfig *)adjustConfig; + +- (void)trackEvent:(nullable ADJEvent *)event; + +- (void)setEnabled:(BOOL)enabled; + +- (void)teardown; + +- (void)appWillOpenUrl:(nonnull NSURL *)url; + +- (void)setOfflineMode:(BOOL)enabled; + +- (void)setDeviceToken:(nonnull NSData *)deviceToken; + +- (void)setPushToken:(nonnull NSString *)pushToken; + +- (void)sendFirstPackages; + +- (void)trackSubsessionEnd; + +- (void)trackSubsessionStart; + +- (void)resetSessionPartnerParameters; + +- (void)resetSessionCallbackParameters; + +- (void)removeSessionPartnerParameter:(nonnull NSString *)key; + +- (void)removeSessionCallbackParameter:(nonnull NSString *)key; + +- (void)addSessionPartnerParameter:(nonnull NSString *)key value:(nonnull NSString *)value; + +- (void)addSessionCallbackParameter:(nonnull NSString *)key value:(nonnull NSString *)value; + +- (void)gdprForgetMe; + +- (void)trackAdRevenue:(nonnull NSString *)source payload:(nonnull NSData *)payload; + +- (void)trackSubscription:(nonnull ADJSubscription *)subscription; + +- (BOOL)isEnabled; + +- (nullable NSString *)adid; + +- (nullable NSString *)idfa; + +- (nullable NSString *)sdkVersion; + +- (nullable ADJAttribution *)attribution; + +- (nullable NSURL *)convertUniversalLink:(nonnull NSURL *)url scheme:(nonnull NSString *)scheme; + +- (void)requestTrackingAuthorizationWithCompletionHandler:(void (^_Nullable)(NSUInteger status))completion; + +- (int)appTrackingAuthorizationStatus; + +- (void)updateConversionValue:(NSInteger)conversionValue; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/Adjust.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/Adjust.h.meta new file mode 100644 index 00000000..60339576 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/Adjust.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 78f041701c2d94787bdb278a5bff4fae +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustSdk.a b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustSdk.a new file mode 100644 index 00000000..6f96f1ab Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustSdk.a differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustSdk.a.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustSdk.a.meta new file mode 100644 index 00000000..bb65f59c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustSdk.a.meta @@ -0,0 +1,147 @@ +fileFormatVersion: 2 +guid: 7ecd19f430df2475dad6b1f0cc22114c +timeCreated: 1460026500 +licenseType: Free +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + '': Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 0 + Exclude tvOS: 1 + data: + first: + '': Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + data: + first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + data: + first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + data: + first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + data: + first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + data: + first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + data: + first: + iPhone: iOS + second: + enabled: 1 + settings: + CompileFlags: + FrameworkDependencies: + data: + first: + tvOS: tvOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.h new file mode 100644 index 00000000..ae8e8c20 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.h @@ -0,0 +1,14 @@ +// +// AdjustUnity.h +// Adjust SDK +// +// Created by Pedro Silva (@nonelse) on 27th March 2014. +// Copyright © 2012-2018 Adjust GmbH. All rights reserved. +// + +/** + * @brief The main interface to Adjust Unity bridge. + */ +@interface AdjustUnity : NSObject + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.h.meta new file mode 100644 index 00000000..321ed8e6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 9ffff8839c6ab418b983add4c597fb87 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.mm b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.mm new file mode 100644 index 00000000..3208d3d6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.mm @@ -0,0 +1,696 @@ +// +// AdjustUnity.mm +// Adjust SDK +// +// Created by Pedro Silva (@nonelse) on 27th March 2014. +// Copyright © 2012-2018 Adjust GmbH. All rights reserved. +// + +#import "Adjust.h" +#import "ADJEvent.h" +#import "ADJConfig.h" +#import "AdjustUnity.h" +#import "AdjustUnityDelegate.h" + +@implementation AdjustUnity + +#pragma mark - Object lifecycle methods + +- (id)init { + self = [super init]; + if (nil == self) { + return nil; + } + return self; +} + +@end + +#pragma mark - Helper C methods + +// Method for converting JSON stirng parameters into NSArray object. +NSArray* convertArrayParameters(const char* cStringJsonArrayParameters) { + if (cStringJsonArrayParameters == NULL) { + return nil; + } + + NSError *error = nil; + NSArray *arrayParameters = nil; + NSString *stringJsonArrayParameters = [NSString stringWithUTF8String:cStringJsonArrayParameters]; + + if (stringJsonArrayParameters != nil) { + NSData *dataJson = [stringJsonArrayParameters dataUsingEncoding:NSUTF8StringEncoding]; + arrayParameters = [NSJSONSerialization JSONObjectWithData:dataJson options:0 error:&error]; + } + if (error != nil) { + NSString *errorMessage = @"Failed to parse json parameters!"; + NSLog(@"%@", errorMessage); + } + + return arrayParameters; +} + +BOOL isStringValid(const char* cString) { + if (cString == NULL) { + return false; + } + + NSString *objcString = [NSString stringWithUTF8String:cString]; + if (objcString == nil) { + return false; + } + if ([objcString isEqualToString:@"ADJ_INVALID"]) { + return false; + } + + return true; +} + +void addValueOrEmpty(NSMutableDictionary *dictionary, NSString *key, NSObject *value) { + if (nil != value) { + if ([value isKindOfClass:[NSString class]]) { + [dictionary setObject:[NSString stringWithFormat:@"%@", value] forKey:key]; + } else if ([value isKindOfClass:[NSNumber class]]) { + [dictionary setObject:[NSString stringWithFormat:@"%@", [((NSNumber *)value) stringValue]] forKey:key]; + } else { + [dictionary setObject:@"" forKey:key]; + } + } else { + [dictionary setObject:@"" forKey:key]; + } +} + +#pragma mark - Publicly available C methods + +extern "C" +{ + void _AdjustLaunchApp(const char* appToken, + const char* environment, + const char* sdkPrefix, + const char* userAgent, + const char* defaultTracker, + const char* externalDeviceId, + const char* urlStrategy, + const char* sceneName, + int allowSuppressLogLevel, + int logLevel, + int isDeviceKnown, + int eventBuffering, + int sendInBackground, + int allowiAdInfoReading, + int allowAdServicesInfoReading, + int allowIdfaReading, + int deactivateSkAdNetworkHandling, + int needsCost, + int64_t secretId, + int64_t info1, + int64_t info2, + int64_t info3, + int64_t info4, + double delayStart, + int launchDeferredDeeplink, + int isAttributionCallbackImplemented, + int isEventSuccessCallbackImplemented, + int isEventFailureCallbackImplemented, + int isSessionSuccessCallbackImplemented, + int isSessionFailureCallbackImplemented, + int isDeferredDeeplinkCallbackImplemented) { + NSString *stringAppToken = isStringValid(appToken) == true ? [NSString stringWithUTF8String:appToken] : nil; + NSString *stringEnvironment = isStringValid(environment) == true ? [NSString stringWithUTF8String:environment] : nil; + NSString *stringSdkPrefix = isStringValid(sdkPrefix) == true ? [NSString stringWithUTF8String:sdkPrefix] : nil; + NSString *stringUserAgent = isStringValid(userAgent) == true ? [NSString stringWithUTF8String:userAgent] : nil; + NSString *stringDefaultTracker = isStringValid(defaultTracker) == true ? [NSString stringWithUTF8String:defaultTracker] : nil; + NSString *stringExternalDeviceId = isStringValid(externalDeviceId) == true ? [NSString stringWithUTF8String:externalDeviceId] : nil; + NSString *stringUrlStrategy = isStringValid(urlStrategy) == true ? [NSString stringWithUTF8String:urlStrategy] : nil; + NSString *stringSceneName = isStringValid(sceneName) == true ? [NSString stringWithUTF8String:sceneName] : nil; + + ADJConfig *adjustConfig; + + if (allowSuppressLogLevel != -1) { + adjustConfig = [ADJConfig configWithAppToken:stringAppToken + environment:stringEnvironment + allowSuppressLogLevel:(BOOL)allowSuppressLogLevel]; + } else { + adjustConfig = [ADJConfig configWithAppToken:stringAppToken + environment:stringEnvironment]; + } + + // Set SDK prefix. + [adjustConfig setSdkPrefix:stringSdkPrefix]; + + // Check if user has selected to implement any of the callbacks. + if (isAttributionCallbackImplemented + || isEventSuccessCallbackImplemented + || isEventFailureCallbackImplemented + || isSessionSuccessCallbackImplemented + || isSessionFailureCallbackImplemented + || isDeferredDeeplinkCallbackImplemented) { + [adjustConfig setDelegate: + [AdjustUnityDelegate getInstanceWithSwizzleOfAttributionCallback:isAttributionCallbackImplemented + eventSuccessCallback:isEventSuccessCallbackImplemented + eventFailureCallback:isEventFailureCallbackImplemented + sessionSuccessCallback:isSessionSuccessCallbackImplemented + sessionFailureCallback:isSessionFailureCallbackImplemented + deferredDeeplinkCallback:isDeferredDeeplinkCallbackImplemented + shouldLaunchDeferredDeeplink:launchDeferredDeeplink + withAdjustUnitySceneName:stringSceneName]]; + } + + // Log level. + if (logLevel != -1) { + [adjustConfig setLogLevel:(ADJLogLevel)logLevel]; + } + + // Event buffering. + if (eventBuffering != -1) { + [adjustConfig setEventBufferingEnabled:(BOOL)eventBuffering]; + } + + // Send in background. + if (sendInBackground != -1) { + [adjustConfig setSendInBackground:(BOOL)sendInBackground]; + } + + // Allow iAd info reading. + if (allowiAdInfoReading != -1) { + [adjustConfig setAllowiAdInfoReading:(BOOL)allowiAdInfoReading]; + } + + // Allow AdServices info reading. + if (allowAdServicesInfoReading != -1) { + [adjustConfig setAllowAdServicesInfoReading:(BOOL)allowAdServicesInfoReading]; + } + + // Deactivate default SKAdNetwork handling. + if (deactivateSkAdNetworkHandling != -1) { + [adjustConfig deactivateSKAdNetworkHandling]; + } + + // Allow IDFA reading. + if (allowIdfaReading != -1) { + [adjustConfig setAllowIdfaReading:(BOOL)allowIdfaReading]; + } + + // Device known. + if (isDeviceKnown != -1) { + [adjustConfig setIsDeviceKnown:(BOOL)isDeviceKnown]; + } + + // Delay start. + if (delayStart != -1) { + [adjustConfig setDelayStart:delayStart]; + } + + // Cost data in attribution callback. + if (needsCost != -1) { + [adjustConfig setNeedsCost:(BOOL)needsCost]; + } + + // User agent. + if (stringUserAgent != nil) { + [adjustConfig setUserAgent:stringUserAgent]; + } + + // Default tracker. + if (stringDefaultTracker != nil) { + [adjustConfig setDefaultTracker:stringDefaultTracker]; + } + + // External device identifier. + if (stringExternalDeviceId != nil) { + [adjustConfig setExternalDeviceId:stringExternalDeviceId]; + } + + // URL strategy. + if (stringUrlStrategy != nil) { + if ([stringUrlStrategy isEqualToString:@"china"]) { + [adjustConfig setUrlStrategy:ADJUrlStrategyChina]; + } else if ([stringUrlStrategy isEqualToString:@"india"]) { + [adjustConfig setUrlStrategy:ADJUrlStrategyIndia]; + } else if ([stringUrlStrategy isEqualToString:@"data-residency-eu"]) { + [adjustConfig setUrlStrategy:ADJDataResidencyEU]; + } + } + + // App secret. + if (secretId != -1 && info1 != -1 && info2 != -1 && info3 != -1 && info4 != 1) { + [adjustConfig setAppSecret:secretId info1:info1 info2:info2 info3:info3 info4:info4]; + } + + // Start the SDK. + [Adjust appDidLaunch:adjustConfig]; + [Adjust trackSubsessionStart]; + } + + void _AdjustTrackEvent(const char* eventToken, + double revenue, + const char* currency, + const char* receipt, + const char* transactionId, + const char* callbackId, + int isReceiptSet, + const char* jsonCallbackParameters, + const char* jsonPartnerParameters) { + NSString *stringEventToken = isStringValid(eventToken) == true ? [NSString stringWithUTF8String:eventToken] : nil; + ADJEvent *event = [ADJEvent eventWithEventToken:stringEventToken]; + + // Revenue and currency. + if (revenue != -1 && currency != NULL) { + NSString *stringCurrency = [NSString stringWithUTF8String:currency]; + [event setRevenue:revenue currency:stringCurrency]; + } + + // Callback parameters. + NSArray *arrayCallbackParameters = convertArrayParameters(jsonCallbackParameters); + if (arrayCallbackParameters != nil) { + NSUInteger count = [arrayCallbackParameters count]; + for (int i = 0; i < count;) { + NSString *key = arrayCallbackParameters[i++]; + NSString *value = arrayCallbackParameters[i++]; + [event addCallbackParameter:key value:value]; + } + } + + NSArray *arrayPartnerParameters = convertArrayParameters(jsonPartnerParameters); + if (arrayPartnerParameters != nil) { + NSUInteger count = [arrayPartnerParameters count]; + for (int i = 0; i < count;) { + NSString *key = arrayPartnerParameters[i++]; + NSString *value = arrayPartnerParameters[i++]; + [event addPartnerParameter:key value:value]; + } + } + + // Transaction ID. + if (transactionId != NULL) { + NSString *stringTransactionId = [NSString stringWithUTF8String:transactionId]; + [event setTransactionId:stringTransactionId]; + } + + // Callback ID. + if (callbackId != NULL) { + NSString *stringCallbackId = [NSString stringWithUTF8String:callbackId]; + [event setCallbackId:stringCallbackId]; + } + + // Receipt (legacy). + if ([[NSNumber numberWithInt:isReceiptSet] boolValue]) { + NSString *stringReceipt = nil; + NSString *stringTransactionId = nil; + + if (receipt != NULL) { + stringReceipt = [NSString stringWithUTF8String:receipt]; + } + if (transactionId != NULL) { + stringTransactionId = [NSString stringWithUTF8String:transactionId]; + } + + [event setReceipt:[stringReceipt dataUsingEncoding:NSUTF8StringEncoding] transactionId:stringTransactionId]; + } + + // Track event. + [Adjust trackEvent:event]; + } + + void _AdjustTrackSubsessionStart() { + [Adjust trackSubsessionStart]; + } + + void _AdjustTrackSubsessionEnd() { + [Adjust trackSubsessionEnd]; + } + + void _AdjustSetEnabled(int enabled) { + BOOL bEnabled = (BOOL)enabled; + [Adjust setEnabled:bEnabled]; + } + + int _AdjustIsEnabled() { + BOOL isEnabled = [Adjust isEnabled]; + int iIsEnabled = (int)isEnabled; + return iIsEnabled; + } + + void _AdjustSetOfflineMode(int enabled) { + BOOL bEnabled = (BOOL)enabled; + [Adjust setOfflineMode:bEnabled]; + } + + void _AdjustSetDeviceToken(const char* deviceToken) { + if (deviceToken != NULL) { + NSString *stringDeviceToken = [NSString stringWithUTF8String:deviceToken]; + [Adjust setPushToken:stringDeviceToken]; + } + } + + void _AdjustAppWillOpenUrl(const char* url) { + if (url != NULL) { + NSString *stringUrl = [NSString stringWithUTF8String:url]; + NSURL *nsUrl; + if ([NSString instancesRespondToSelector:@selector(stringByAddingPercentEncodingWithAllowedCharacters:)]) { + nsUrl = [NSURL URLWithString:[stringUrl stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLFragmentAllowedCharacterSet]]]; + } else { +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" + nsUrl = [NSURL URLWithString:[stringUrl stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]]; + } +#pragma clang diagnostic pop + + [Adjust appWillOpenUrl:nsUrl]; + } + } + + char* _AdjustGetIdfa() { + NSString *idfa = [Adjust idfa]; + if (nil == idfa) { + return NULL; + } + + const char* idfaCString = [idfa UTF8String]; + if (NULL == idfaCString) { + return NULL; + } + + char* idfaCStringCopy = strdup(idfaCString); + return idfaCStringCopy; + } + + char* _AdjustGetAdid() { + NSString *adid = [Adjust adid]; + if (nil == adid) { + return NULL; + } + + const char* adidCString = [adid UTF8String]; + if (NULL == adidCString) { + return NULL; + } + + char* adidCStringCopy = strdup(adidCString); + return adidCStringCopy; + } + + char* _AdjustGetSdkVersion() { + NSString *sdkVersion = [Adjust sdkVersion]; + if (nil == sdkVersion) { + return NULL; + } + + const char* sdkVersionCString = [sdkVersion UTF8String]; + if (NULL == sdkVersionCString) { + return NULL; + } + + char* sdkVersionCStringCopy = strdup(sdkVersionCString); + return sdkVersionCStringCopy; + } + + char* _AdjustGetAttribution() { + ADJAttribution *attribution = [Adjust attribution]; + if (nil == attribution) { + return NULL; + } + + NSMutableDictionary *dictionary = [NSMutableDictionary dictionary]; + addValueOrEmpty(dictionary, @"trackerToken", attribution.trackerToken); + addValueOrEmpty(dictionary, @"trackerName", attribution.trackerName); + addValueOrEmpty(dictionary, @"network", attribution.network); + addValueOrEmpty(dictionary, @"campaign", attribution.campaign); + addValueOrEmpty(dictionary, @"creative", attribution.creative); + addValueOrEmpty(dictionary, @"adgroup", attribution.adgroup); + addValueOrEmpty(dictionary, @"clickLabel", attribution.clickLabel); + addValueOrEmpty(dictionary, @"adid", attribution.adid); + addValueOrEmpty(dictionary, @"costType", attribution.costType); + addValueOrEmpty(dictionary, @"costAmount", attribution.costAmount); + addValueOrEmpty(dictionary, @"costCurrency", attribution.costCurrency); + + NSData *dataAttribution = [NSJSONSerialization dataWithJSONObject:dictionary options:0 error:nil]; + NSString *stringAttribution = [[NSString alloc] initWithBytes:[dataAttribution bytes] + length:[dataAttribution length] + encoding:NSUTF8StringEncoding]; + const char* attributionCString = [stringAttribution UTF8String]; + char* attributionCStringCopy = strdup(attributionCString); + return attributionCStringCopy; + } + + void _AdjustSendFirstPackages() { + [Adjust sendFirstPackages]; + } + + void _AdjustGdprForgetMe() { + [Adjust gdprForgetMe]; + } + + void _AdjustDisableThirdPartySharing() { + [Adjust disableThirdPartySharing]; + } + + void _AdjustAddSessionPartnerParameter(const char* key, const char* value) { + if (key != NULL && value != NULL) { + NSString *stringKey = [NSString stringWithUTF8String:key]; + NSString *stringValue = [NSString stringWithUTF8String:value]; + [Adjust addSessionPartnerParameter:stringKey value:stringValue]; + } + } + + void _AdjustAddSessionCallbackParameter(const char* key, const char* value) { + if (key != NULL && value != NULL) { + NSString *stringKey = [NSString stringWithUTF8String:key]; + NSString *stringValue = [NSString stringWithUTF8String:value]; + [Adjust addSessionCallbackParameter:stringKey value:stringValue]; + } + } + + void _AdjustRemoveSessionPartnerParameter(const char* key) { + if (key != NULL) { + NSString *stringKey = [NSString stringWithUTF8String:key]; + [Adjust removeSessionPartnerParameter:stringKey]; + } + } + + void _AdjustRemoveSessionCallbackParameter(const char* key) { + if (key != NULL) { + NSString *stringKey = [NSString stringWithUTF8String:key]; + [Adjust removeSessionCallbackParameter:stringKey]; + } + } + + void _AdjustResetSessionPartnerParameters() { + [Adjust resetSessionPartnerParameters]; + } + + void _AdjustResetSessionCallbackParameters() { + [Adjust resetSessionCallbackParameters]; + } + + void _AdjustTrackAdRevenue(const char* source, const char* payload) { + if (source != NULL && payload != NULL) { + NSString *stringSource = [NSString stringWithUTF8String:source]; + NSString *stringPayload = [NSString stringWithUTF8String:payload]; + NSData *dataPayload = [stringPayload dataUsingEncoding:NSUTF8StringEncoding]; + [Adjust trackAdRevenue:stringSource payload:dataPayload]; + } + } + + void _AdjustTrackAppStoreSubscription(const char* price, + const char* currency, + const char* transactionId, + const char* receipt, + const char* billingStore, + const char* transactionDate, + const char* salesRegion, + const char* jsonCallbackParameters, + const char* jsonPartnerParameters) { + // Mandatory fields. + NSDecimalNumber *mPrice; + NSString *mCurrency; + NSString *mTransactionId; + NSData *mReceipt; + NSString *mBillingStore; + + // Price. + if (price != NULL) { + mPrice = [NSDecimalNumber decimalNumberWithString:[NSString stringWithUTF8String:price]]; + } + + // Currency. + if (currency != NULL) { + mCurrency = [NSString stringWithUTF8String:currency]; + } + + // Transaction ID. + if (transactionId != NULL) { + mTransactionId = [NSString stringWithUTF8String:transactionId]; + } + + // Receipt. + if (receipt != NULL) { + mReceipt = [[NSString stringWithUTF8String:receipt] dataUsingEncoding:NSUTF8StringEncoding]; + } + + // Billing store (not used ATM, maybe in the future). + if (billingStore != NULL) { + mBillingStore = [NSString stringWithUTF8String:billingStore]; + } + + ADJSubscription *subscription = [[ADJSubscription alloc] initWithPrice:mPrice + currency:mCurrency + transactionId:mTransactionId + andReceipt:mReceipt]; + + // Optional fields. + + // Transaction date. + if (transactionDate != NULL) { + NSTimeInterval transactionDateInterval = [[NSString stringWithUTF8String:transactionDate] doubleValue]; + NSDate *oTransactionDate = [NSDate dateWithTimeIntervalSince1970:transactionDateInterval]; + [subscription setTransactionDate:oTransactionDate]; + } + + // Sales region. + if (salesRegion != NULL) { + NSString *oSalesRegion = [NSString stringWithUTF8String:salesRegion]; + [subscription setSalesRegion:oSalesRegion]; + } + + // Callback parameters. + NSArray *arrayCallbackParameters = convertArrayParameters(jsonCallbackParameters); + if (arrayCallbackParameters != nil) { + NSUInteger count = [arrayCallbackParameters count]; + for (int i = 0; i < count;) { + NSString *key = arrayCallbackParameters[i++]; + NSString *value = arrayCallbackParameters[i++]; + [subscription addCallbackParameter:key value:value]; + } + } + + // Partner parameters. + NSArray *arrayPartnerParameters = convertArrayParameters(jsonPartnerParameters); + if (arrayPartnerParameters != nil) { + NSUInteger count = [arrayPartnerParameters count]; + for (int i = 0; i < count;) { + NSString *key = arrayPartnerParameters[i++]; + NSString *value = arrayPartnerParameters[i++]; + [subscription addPartnerParameter:key value:value]; + } + } + + // Track subscription. + [Adjust trackSubscription:subscription]; + } + + void _AdjustTrackThirdPartySharing(int enabled, const char* jsonGranularOptions) { + NSNumber *nEnabled = enabled >= 0 ? [NSNumber numberWithInt:enabled] : nil; + ADJThirdPartySharing *adjustThirdPartySharing = [[ADJThirdPartySharing alloc] initWithIsEnabledNumberBool:nEnabled]; + + NSArray *arrayGranularOptions = convertArrayParameters(jsonGranularOptions); + if (arrayGranularOptions != nil) { + NSUInteger count = [arrayGranularOptions count]; + for (int i = 0; i < count;) { + NSString *partnerName = arrayGranularOptions[i++]; + NSString *granularOptions = arrayGranularOptions[i++]; + // granularOptions is now NSString which pretty much contains array of partner key-value pairs + if (granularOptions != nil) { + NSData *dataJson = [granularOptions dataUsingEncoding:NSUTF8StringEncoding]; + NSArray *partnerGranularOptions = [NSJSONSerialization JSONObjectWithData:dataJson options:0 error:nil]; + if (partnerGranularOptions != nil) { + // in here we have partner and key-value pair for it + for (int j = 0; j < [partnerGranularOptions count];) { + [adjustThirdPartySharing addGranularOption:partnerName + key:partnerGranularOptions[j++] + value:partnerGranularOptions[j++]]; + } + } + } + } + } + + [Adjust trackThirdPartySharing:adjustThirdPartySharing]; + } + + void _AdjustTrackMeasurementConsent(int enabled) { + BOOL bEnabled = (BOOL)enabled; + [Adjust trackMeasurementConsent:bEnabled]; + } + + void _AdjustRequestTrackingAuthorizationWithCompletionHandler(const char* sceneName) { + NSString *stringSceneName = isStringValid(sceneName) == true ? [NSString stringWithUTF8String:sceneName] : nil; + if (stringSceneName == nil) { + return; + } + + [Adjust requestTrackingAuthorizationWithCompletionHandler:^(NSUInteger status) { + NSString *stringStatus = [NSString stringWithFormat:@"%tu", status]; + const char* charStatus = [stringStatus UTF8String]; + UnitySendMessage([stringSceneName UTF8String], "GetAuthorizationStatus", charStatus); + }]; + } + + void _AdjustUpdateConversionValue(int conversionValue) { + [Adjust updateConversionValue:conversionValue]; + } + + int _AdjustGetAppTrackingAuthorizationStatus() { + return [Adjust appTrackingAuthorizationStatus]; + } + + void _AdjustSetTestOptions(const char* baseUrl, + const char* gdprUrl, + const char* subscriptionUrl, + const char* extraPath, + long timerIntervalInMilliseconds, + long timerStartInMilliseconds, + long sessionIntervalInMilliseconds, + long subsessionIntervalInMilliseconds, + int teardown, + int deleteState, + int noBackoffWait, + int iAdFrameworkEnabled, + int adServicesFrameworkEnabled) { + AdjustTestOptions *testOptions = [[AdjustTestOptions alloc] init]; + + NSString *stringBaseUrl = isStringValid(baseUrl) == true ? [NSString stringWithUTF8String:baseUrl] : nil; + if (stringBaseUrl != nil) { + [testOptions setBaseUrl:stringBaseUrl]; + } + + NSString *stringGdprUrl = isStringValid(baseUrl) == true ? [NSString stringWithUTF8String:gdprUrl] : nil; + if (stringGdprUrl != nil) { + [testOptions setGdprUrl:stringGdprUrl]; + } + + NSString *stringSubscriptionUrl = isStringValid(baseUrl) == true ? [NSString stringWithUTF8String:subscriptionUrl] : nil; + if (stringSubscriptionUrl != nil) { + [testOptions setSubscriptionUrl:stringSubscriptionUrl]; + } + + NSString *stringExtraPath = isStringValid(extraPath) == true ? [NSString stringWithUTF8String:extraPath] : nil; + if (stringExtraPath != nil && [stringExtraPath length] > 0) { + [testOptions setExtraPath:stringExtraPath]; + } + + testOptions.timerIntervalInMilliseconds = [NSNumber numberWithLong:timerIntervalInMilliseconds]; + testOptions.timerStartInMilliseconds = [NSNumber numberWithLong:timerStartInMilliseconds]; + testOptions.sessionIntervalInMilliseconds = [NSNumber numberWithLong:sessionIntervalInMilliseconds]; + testOptions.subsessionIntervalInMilliseconds = [NSNumber numberWithLong:subsessionIntervalInMilliseconds]; + + if (teardown != -1) { + [AdjustUnityDelegate teardown]; + [testOptions setTeardown:(BOOL)teardown]; + } + if (deleteState != -1) { + [testOptions setDeleteState:(BOOL)deleteState]; + } + if (noBackoffWait != -1) { + [testOptions setNoBackoffWait:(BOOL)noBackoffWait]; + } + if (iAdFrameworkEnabled != -1) { + [testOptions setIAdFrameworkEnabled:(BOOL)iAdFrameworkEnabled]; + } + if (adServicesFrameworkEnabled != -1) { + [testOptions setAdServicesFrameworkEnabled:(BOOL)adServicesFrameworkEnabled]; + } + + [Adjust setTestOptions:testOptions]; + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.mm.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.mm.meta new file mode 100644 index 00000000..40dc15ca --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnity.mm.meta @@ -0,0 +1,37 @@ +fileFormatVersion: 2 +guid: 3e17e20d987e4449489d9e3accbd8602 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.h b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.h new file mode 100644 index 00000000..f9e442c9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.h @@ -0,0 +1,55 @@ +// +// AdjustUnityDelegate.h +// Adjust SDK +// +// Created by Uglješa Erceg (@uerceg) on 5th December 2016. +// Copyright © 2012-2018 Adjust GmbH. All rights reserved. +// + +#import "Adjust.h" + +/** + * @brief The main interface to Adjust Unity delegate. Used to do callback methods swizzling where needed. + */ +@interface AdjustUnityDelegate : NSObject + +/** + * @brief Boolean indicating whether deferred deep link should be launched by SDK or not. + */ +@property (nonatomic) BOOL shouldLaunchDeferredDeeplink; + +/** + * @brief Name of the Unity scene that loads Adjust SDK. + */ +@property (nonatomic, copy) NSString *adjustUnitySceneName; + +/** + * @brief Get instance of the AdjustUnityDelegate with properly swizzled callback methods. + * + * @param swizzleAttributionCallback Indicator whether attribution callback should be swizzled or not. + * @param swizzleEventSuccessCallback Indicator whether event success callback should be swizzled or not. + * @param swizzleEventFailureCallback Indicator whether event failure callback should be swizzled or not. + * @param swizzleSessionSuccessCallback Indicator whether session success callback should be swizzled or not. + * @param swizzleSessionFailureCallback Indicator whether session failure callback should be swizzled or not. + * @param swizzleDeferredDeeplinkCallback Indicator whether deferred deep link callback should be swizzled or not. + * @param shouldLaunchDeferredDeeplink Indicator whether SDK should launch deferred deep link by default or not. + * @param adjustUnitySceneName Name of the Unity scene that loads Adjust SDK. + * + * @return AdjustUnityDelegate object instance with properly swizzled callback methods. + */ ++ (id)getInstanceWithSwizzleOfAttributionCallback:(BOOL)swizzleAttributionCallback + eventSuccessCallback:(BOOL)swizzleEventSuccessCallback + eventFailureCallback:(BOOL)swizzleEventFailureCallback + sessionSuccessCallback:(BOOL)swizzleSessionSuccessCallback + sessionFailureCallback:(BOOL)swizzleSessionFailureCallback + deferredDeeplinkCallback:(BOOL)swizzleDeferredDeeplinkCallback + shouldLaunchDeferredDeeplink:(BOOL)shouldLaunchDeferredDeeplink + withAdjustUnitySceneName:(NSString *)adjustUnitySceneName; + +/** + * @brief Teardown method used to reset static AdjustUnityDelegate instance. + * Used for testing purposes only. + */ ++ (void)teardown; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.h.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.h.meta new file mode 100644 index 00000000..e3ecdbcc --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.h.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 5d2beef19c617f74fbca612cc97e3c60 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.mm b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.mm new file mode 100644 index 00000000..c12fa718 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.mm @@ -0,0 +1,239 @@ +// +// AdjustUnityDelegate.mm +// Adjust SDK +// +// Created by Uglješa Erceg (@uerceg) on 5th December 2016. +// Copyright © 2012-2018 Adjust GmbH. All rights reserved. +// + +#import +#import "AdjustUnityDelegate.h" + +static dispatch_once_t onceToken; +static AdjustUnityDelegate *defaultInstance = nil; + +@implementation AdjustUnityDelegate + +#pragma mark - Object lifecycle methods + +- (id)init { + self = [super init]; + if (nil == self) { + return nil; + } + return self; +} + +#pragma mark - Public methods + ++ (id)getInstanceWithSwizzleOfAttributionCallback:(BOOL)swizzleAttributionCallback + eventSuccessCallback:(BOOL)swizzleEventSuccessCallback + eventFailureCallback:(BOOL)swizzleEventFailureCallback + sessionSuccessCallback:(BOOL)swizzleSessionSuccessCallback + sessionFailureCallback:(BOOL)swizzleSessionFailureCallback + deferredDeeplinkCallback:(BOOL)swizzleDeferredDeeplinkCallback + shouldLaunchDeferredDeeplink:(BOOL)shouldLaunchDeferredDeeplink + withAdjustUnitySceneName:(NSString *)adjustUnitySceneName { + dispatch_once(&onceToken, ^{ + defaultInstance = [[AdjustUnityDelegate alloc] init]; + + // Do the swizzling where and if needed. + if (swizzleAttributionCallback) { + [defaultInstance swizzleOriginalSelector:@selector(adjustAttributionChanged:) + withSelector:@selector(adjustAttributionChangedWannabe:)]; + } + if (swizzleEventSuccessCallback) { + [defaultInstance swizzleOriginalSelector:@selector(adjustEventTrackingSucceeded:) + withSelector:@selector(adjustEventTrackingSucceededWannabe:)]; + } + if (swizzleEventFailureCallback) { + [defaultInstance swizzleOriginalSelector:@selector(adjustEventTrackingFailed:) + withSelector:@selector(adjustEventTrackingFailedWannabe:)]; + } + if (swizzleSessionSuccessCallback) { + [defaultInstance swizzleOriginalSelector:@selector(adjustSessionTrackingSucceeded:) + withSelector:@selector(adjustSessionTrackingSucceededWannabe:)]; + } + if (swizzleSessionFailureCallback) { + [defaultInstance swizzleOriginalSelector:@selector(adjustSessionTrackingFailed:) + withSelector:@selector(adjustSessionTrackingFailedWannabe:)]; + } + if (swizzleDeferredDeeplinkCallback) { + [defaultInstance swizzleOriginalSelector:@selector(adjustDeeplinkResponse:) + withSelector:@selector(adjustDeeplinkResponseWannabe:)]; + } + + [defaultInstance setShouldLaunchDeferredDeeplink:shouldLaunchDeferredDeeplink]; + [defaultInstance setAdjustUnitySceneName:adjustUnitySceneName]; + }); + + return defaultInstance; +} + ++ (void)teardown { + defaultInstance = nil; + onceToken = 0; +} + +#pragma mark - Private & helper methods + +- (void)adjustAttributionChangedWannabe:(ADJAttribution *)attribution { + if (attribution == nil) { + return; + } + + NSMutableDictionary *dictionary = [NSMutableDictionary dictionary]; + [self addValueOrEmpty:attribution.trackerToken forKey:@"trackerToken" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.trackerName forKey:@"trackerName" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.network forKey:@"network" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.campaign forKey:@"campaign" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.creative forKey:@"creative" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.adgroup forKey:@"adgroup" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.clickLabel forKey:@"clickLabel" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.adid forKey:@"adid" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.costType forKey:@"costType" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.costAmount forKey:@"costAmount" toDictionary:dictionary]; + [self addValueOrEmpty:attribution.costCurrency forKey:@"costCurrency" toDictionary:dictionary]; + + NSData *dataAttribution = [NSJSONSerialization dataWithJSONObject:dictionary options:0 error:nil]; + NSString *stringAttribution = [[NSString alloc] initWithBytes:[dataAttribution bytes] + length:[dataAttribution length] + encoding:NSUTF8StringEncoding]; + const char* charArrayAttribution = [stringAttribution UTF8String]; + UnitySendMessage([self.adjustUnitySceneName UTF8String], "GetNativeAttribution", charArrayAttribution); +} + +- (void)adjustEventTrackingSucceededWannabe:(ADJEventSuccess *)eventSuccessResponseData { + if (nil == eventSuccessResponseData) { + return; + } + + NSMutableDictionary *dictionary = [NSMutableDictionary dictionary]; + [self addValueOrEmpty:eventSuccessResponseData.message forKey:@"message" toDictionary:dictionary]; + [self addValueOrEmpty:eventSuccessResponseData.timeStamp forKey:@"timestamp" toDictionary:dictionary]; + [self addValueOrEmpty:eventSuccessResponseData.adid forKey:@"adid" toDictionary:dictionary]; + [self addValueOrEmpty:eventSuccessResponseData.eventToken forKey:@"eventToken" toDictionary:dictionary]; + [self addValueOrEmpty:eventSuccessResponseData.callbackId forKey:@"callbackId" toDictionary:dictionary]; + if (eventSuccessResponseData.jsonResponse != nil) { + [dictionary setObject:eventSuccessResponseData.jsonResponse forKey:@"jsonResponse"]; + } + + NSData *dataEventSuccess = [NSJSONSerialization dataWithJSONObject:dictionary options:0 error:nil]; + NSString *stringEventSuccess = [[NSString alloc] initWithBytes:[dataEventSuccess bytes] + length:[dataEventSuccess length] + encoding:NSUTF8StringEncoding]; + const char* charArrayEventSuccess = [stringEventSuccess UTF8String]; + UnitySendMessage([self.adjustUnitySceneName UTF8String], "GetNativeEventSuccess", charArrayEventSuccess); +} + +- (void)adjustEventTrackingFailedWannabe:(ADJEventFailure *)eventFailureResponseData { + if (nil == eventFailureResponseData) { + return; + } + + NSMutableDictionary *dictionary = [NSMutableDictionary dictionary]; + [self addValueOrEmpty:eventFailureResponseData.message forKey:@"message" toDictionary:dictionary]; + [self addValueOrEmpty:eventFailureResponseData.timeStamp forKey:@"timestamp" toDictionary:dictionary]; + [self addValueOrEmpty:eventFailureResponseData.adid forKey:@"adid" toDictionary:dictionary]; + [self addValueOrEmpty:eventFailureResponseData.eventToken forKey:@"eventToken" toDictionary:dictionary]; + [self addValueOrEmpty:eventFailureResponseData.callbackId forKey:@"callbackId" toDictionary:dictionary]; + [dictionary setObject:(eventFailureResponseData.willRetry ? @"true" : @"false") forKey:@"willRetry"]; + if (eventFailureResponseData.jsonResponse != nil) { + [dictionary setObject:eventFailureResponseData.jsonResponse forKey:@"jsonResponse"]; + } + + NSData *dataEventFailure = [NSJSONSerialization dataWithJSONObject:dictionary options:0 error:nil]; + NSString *stringEventFailure = [[NSString alloc] initWithBytes:[dataEventFailure bytes] + length:[dataEventFailure length] + encoding:NSUTF8StringEncoding]; + const char* charArrayEventFailure = [stringEventFailure UTF8String]; + UnitySendMessage([self.adjustUnitySceneName UTF8String], "GetNativeEventFailure", charArrayEventFailure); +} + +- (void)adjustSessionTrackingSucceededWannabe:(ADJSessionSuccess *)sessionSuccessResponseData { + if (nil == sessionSuccessResponseData) { + return; + } + + NSMutableDictionary *dictionary = [NSMutableDictionary dictionary]; + [self addValueOrEmpty:sessionSuccessResponseData.message forKey:@"message" toDictionary:dictionary]; + [self addValueOrEmpty:sessionSuccessResponseData.timeStamp forKey:@"timestamp" toDictionary:dictionary]; + [self addValueOrEmpty:sessionSuccessResponseData.adid forKey:@"adid" toDictionary:dictionary]; + if (sessionSuccessResponseData.jsonResponse != nil) { + [dictionary setObject:sessionSuccessResponseData.jsonResponse forKey:@"jsonResponse"]; + } + + NSData *dataSessionSuccess = [NSJSONSerialization dataWithJSONObject:dictionary options:0 error:nil]; + NSString *stringSessionSuccess = [[NSString alloc] initWithBytes:[dataSessionSuccess bytes] + length:[dataSessionSuccess length] + encoding:NSUTF8StringEncoding]; + const char* charArraySessionSuccess = [stringSessionSuccess UTF8String]; + UnitySendMessage([self.adjustUnitySceneName UTF8String], "GetNativeSessionSuccess", charArraySessionSuccess); +} + +- (void)adjustSessionTrackingFailedWannabe:(ADJSessionFailure *)sessionFailureResponseData { + if (nil == sessionFailureResponseData) { + return; + } + + NSMutableDictionary *dictionary = [NSMutableDictionary dictionary]; + [self addValueOrEmpty:sessionFailureResponseData.message forKey:@"message" toDictionary:dictionary]; + [self addValueOrEmpty:sessionFailureResponseData.timeStamp forKey:@"timestamp" toDictionary:dictionary]; + [self addValueOrEmpty:sessionFailureResponseData.adid forKey:@"adid" toDictionary:dictionary]; + [dictionary setObject:(sessionFailureResponseData.willRetry ? @"true" : @"false") forKey:@"willRetry"]; + if (sessionFailureResponseData.jsonResponse != nil) { + [dictionary setObject:sessionFailureResponseData.jsonResponse forKey:@"jsonResponse"]; + } + + NSData *dataSessionFailure = [NSJSONSerialization dataWithJSONObject:dictionary options:0 error:nil]; + NSString *stringSessionFailure = [[NSString alloc] initWithBytes:[dataSessionFailure bytes] + length:[dataSessionFailure length] + encoding:NSUTF8StringEncoding]; + const char* charArraySessionFailure = [stringSessionFailure UTF8String]; + UnitySendMessage([self.adjustUnitySceneName UTF8String], "GetNativeSessionFailure", charArraySessionFailure); +} + +- (BOOL)adjustDeeplinkResponseWannabe:(NSURL *)deeplink { + NSString *stringDeeplink = [deeplink absoluteString]; + const char* charDeeplink = [stringDeeplink UTF8String]; + UnitySendMessage([self.adjustUnitySceneName UTF8String], "GetNativeDeferredDeeplink", charDeeplink); + return _shouldLaunchDeferredDeeplink; +} + +- (void)swizzleOriginalSelector:(SEL)originalSelector + withSelector:(SEL)swizzledSelector { + Class className = [self class]; + Method originalMethod = class_getInstanceMethod(className, originalSelector); + Method swizzledMethod = class_getInstanceMethod(className, swizzledSelector); + + BOOL didAddMethod = class_addMethod(className, + originalSelector, + method_getImplementation(swizzledMethod), + method_getTypeEncoding(swizzledMethod)); + if (didAddMethod) { + class_replaceMethod(className, + swizzledSelector, + method_getImplementation(originalMethod), + method_getTypeEncoding(originalMethod)); + } else { + method_exchangeImplementations(originalMethod, swizzledMethod); + } +} + +- (void)addValueOrEmpty:(NSObject *)value + forKey:(NSString *)key + toDictionary:(NSMutableDictionary *)dictionary { + if (nil != value) { + if ([value isKindOfClass:[NSString class]]) { + [dictionary setObject:[NSString stringWithFormat:@"%@", value] forKey:key]; + } else if ([value isKindOfClass:[NSNumber class]]) { + [dictionary setObject:[NSString stringWithFormat:@"%@", [((NSNumber *)value) stringValue]] forKey:key]; + } else { + [dictionary setObject:@"" forKey:key]; + } + } else { + [dictionary setObject:@"" forKey:key]; + } +} + +@end diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.mm.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.mm.meta new file mode 100644 index 00000000..fa0d09e7 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustUnityDelegate.mm.meta @@ -0,0 +1,37 @@ +fileFormatVersion: 2 +guid: 81438eed05b2e4b489f13efc94d5476a +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustiOS.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustiOS.cs new file mode 100644 index 00000000..0cd86113 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustiOS.cs @@ -0,0 +1,497 @@ +using System; +using System.Collections.Generic; +using System.Runtime.InteropServices; +using UnityEngine; + +namespace com.adjust.sdk +{ +#if UNITY_IOS + public class AdjustiOS + { + private const string sdkPrefix = "unity4.28.0"; + + [DllImport("__Internal")] + private static extern void _AdjustLaunchApp( + string appToken, + string environment, + string sdkPrefix, + string userAgent, + string defaultTracker, + string extenralDeviceId, + string urlStrategy, + string sceneName, + int allowSuppressLogLevel, + int logLevel, + int isDeviceKnown, + int eventBuffering, + int sendInBackground, + int allowiAdInfoReading, + int allowAdServicesInfoReading, + int allowIdfaReading, + int deactivateSkAdNetworkHandling, + int needsCost, + long secretId, + long info1, + long info2, + long info3, + long info4, + double delayStart, + int launchDeferredDeeplink, + int isAttributionCallbackImplemented, + int isEventSuccessCallbackImplemented, + int isEventFailureCallbackImplemented, + int isSessionSuccessCallbackImplemented, + int isSessionFailureCallbackImplemented, + int isDeferredDeeplinkCallbackImplemented); + + [DllImport("__Internal")] + private static extern void _AdjustTrackEvent( + string eventToken, + double revenue, + string currency, + string receipt, + string transactionId, + string callbackId, + int isReceiptSet, + string jsonCallbackParameters, + string jsonPartnerParameters); + + [DllImport("__Internal")] + private static extern void _AdjustSetEnabled(int enabled); + + [DllImport("__Internal")] + private static extern int _AdjustIsEnabled(); + + [DllImport("__Internal")] + private static extern void _AdjustSetOfflineMode(int enabled); + + [DllImport("__Internal")] + private static extern void _AdjustSetDeviceToken(string deviceToken); + + [DllImport("__Internal")] + private static extern void _AdjustAppWillOpenUrl(string url); + + [DllImport("__Internal")] + private static extern string _AdjustGetIdfa(); + + [DllImport("__Internal")] + private static extern string _AdjustGetAdid(); + + [DllImport("__Internal")] + private static extern string _AdjustGetSdkVersion(); + + [DllImport("__Internal")] + private static extern void _AdjustGdprForgetMe(); + + [DllImport("__Internal")] + private static extern void _AdjustDisableThirdPartySharing(); + + [DllImport("__Internal")] + private static extern string _AdjustGetAttribution(); + + [DllImport("__Internal")] + private static extern void _AdjustSendFirstPackages(); + + [DllImport("__Internal")] + private static extern void _AdjustAddSessionPartnerParameter(string key, string value); + + [DllImport("__Internal")] + private static extern void _AdjustAddSessionCallbackParameter(string key, string value); + + [DllImport("__Internal")] + private static extern void _AdjustRemoveSessionPartnerParameter(string key); + + [DllImport("__Internal")] + private static extern void _AdjustRemoveSessionCallbackParameter(string key); + + [DllImport("__Internal")] + private static extern void _AdjustResetSessionPartnerParameters(); + + [DllImport("__Internal")] + private static extern void _AdjustResetSessionCallbackParameters(); + + [DllImport("__Internal")] + private static extern void _AdjustTrackAdRevenue(string source, string payload); + + [DllImport("__Internal")] + private static extern void _AdjustTrackAppStoreSubscription( + string price, + string currency, + string transactionId, + string receipt, + string billingStore, + string transactionDate, + string salesRegion, + string jsonCallbackParameters, + string jsonPartnerParameters); + + [DllImport("__Internal")] + private static extern void _AdjustTrackThirdPartySharing(int enabled, string jsonGranularOptions); + + [DllImport("__Internal")] + private static extern void _AdjustTrackMeasurementConsent(int enabled); + + [DllImport("__Internal")] + private static extern void _AdjustSetTestOptions( + string baseUrl, + string gdprUrl, + string subscriptionUrl, + string extraPath, + long timerIntervalInMilliseconds, + long timerStartInMilliseconds, + long sessionIntervalInMilliseconds, + long subsessionIntervalInMilliseconds, + int teardown, + int deleteState, + int noBackoffWait, + int iAdFrameworkEnabled, + int adServicesFrameworkEnabled); + + [DllImport("__Internal")] + private static extern void _AdjustRequestTrackingAuthorizationWithCompletionHandler(string sceneName); + + [DllImport("__Internal")] + private static extern void _AdjustUpdateConversionValue(int conversionValue); + + [DllImport("__Internal")] + private static extern int _AdjustGetAppTrackingAuthorizationStatus(); + + [DllImport("__Internal")] + private static extern void _AdjustTrackSubsessionStart(); + + [DllImport("__Internal")] + private static extern void _AdjustTrackSubsessionEnd(); + + public AdjustiOS() {} + + public static void Start(AdjustConfig adjustConfig) + { + string appToken = adjustConfig.appToken != null ? adjustConfig.appToken : "ADJ_INVALID"; + string sceneName = adjustConfig.sceneName != null ? adjustConfig.sceneName : "ADJ_INVALID"; + string userAgent = adjustConfig.userAgent != null ? adjustConfig.userAgent : "ADJ_INVALID"; + string defaultTracker = adjustConfig.defaultTracker != null ? adjustConfig.defaultTracker : "ADJ_INVALID"; + string externalDeviceId = adjustConfig.externalDeviceId != null ? adjustConfig.externalDeviceId : "ADJ_INVALID"; + string urlStrategy = adjustConfig.urlStrategy != null ? adjustConfig.urlStrategy : "ADJ_INVALID"; + string environment = adjustConfig.environment.ToLowercaseString(); + long info1 = AdjustUtils.ConvertLong(adjustConfig.info1); + long info2 = AdjustUtils.ConvertLong(adjustConfig.info2); + long info3 = AdjustUtils.ConvertLong(adjustConfig.info3); + long info4 = AdjustUtils.ConvertLong(adjustConfig.info4); + long secretId = AdjustUtils.ConvertLong(adjustConfig.secretId); + double delayStart = AdjustUtils.ConvertDouble(adjustConfig.delayStart); + int logLevel = AdjustUtils.ConvertLogLevel(adjustConfig.logLevel); + int isDeviceKnown = AdjustUtils.ConvertBool(adjustConfig.isDeviceKnown); + int sendInBackground = AdjustUtils.ConvertBool(adjustConfig.sendInBackground); + int eventBufferingEnabled = AdjustUtils.ConvertBool(adjustConfig.eventBufferingEnabled); + int allowiAdInfoReading = AdjustUtils.ConvertBool(adjustConfig.allowiAdInfoReading); + int allowAdServicesInfoReading = AdjustUtils.ConvertBool(adjustConfig.allowAdServicesInfoReading); + int allowIdfaReading = AdjustUtils.ConvertBool(adjustConfig.allowIdfaReading); + int allowSuppressLogLevel = AdjustUtils.ConvertBool(adjustConfig.allowSuppressLogLevel); + int launchDeferredDeeplink = AdjustUtils.ConvertBool(adjustConfig.launchDeferredDeeplink); + int deactivateSkAdNetworkHandling = AdjustUtils.ConvertBool(adjustConfig.skAdNetworkHandling); + int needsCost = AdjustUtils.ConvertBool(adjustConfig.needsCost); + int isAttributionCallbackImplemented = AdjustUtils.ConvertBool(adjustConfig.getAttributionChangedDelegate() != null); + int isEventSuccessCallbackImplemented = AdjustUtils.ConvertBool(adjustConfig.getEventSuccessDelegate() != null); + int isEventFailureCallbackImplemented = AdjustUtils.ConvertBool(adjustConfig.getEventFailureDelegate() != null); + int isSessionSuccessCallbackImplemented = AdjustUtils.ConvertBool(adjustConfig.getSessionSuccessDelegate() != null); + int isSessionFailureCallbackImplemented = AdjustUtils.ConvertBool(adjustConfig.getSessionFailureDelegate() != null); + int isDeferredDeeplinkCallbackImplemented = AdjustUtils.ConvertBool(adjustConfig.getDeferredDeeplinkDelegate() != null); + + _AdjustLaunchApp( + appToken, + environment, + sdkPrefix, + userAgent, + defaultTracker, + externalDeviceId, + urlStrategy, + sceneName, + allowSuppressLogLevel, + logLevel, + isDeviceKnown, + eventBufferingEnabled, + sendInBackground, + allowiAdInfoReading, + allowAdServicesInfoReading, + allowIdfaReading, + deactivateSkAdNetworkHandling, + needsCost, + secretId, + info1, + info2, + info3, + info4, + delayStart, + launchDeferredDeeplink, + isAttributionCallbackImplemented, + isEventSuccessCallbackImplemented, + isEventFailureCallbackImplemented, + isSessionSuccessCallbackImplemented, + isSessionFailureCallbackImplemented, + isDeferredDeeplinkCallbackImplemented); + } + + public static void TrackEvent(AdjustEvent adjustEvent) + { + int isReceiptSet = AdjustUtils.ConvertBool(adjustEvent.isReceiptSet); + double revenue = AdjustUtils.ConvertDouble(adjustEvent.revenue); + string eventToken = adjustEvent.eventToken; + string currency = adjustEvent.currency; + string receipt = adjustEvent.receipt; + string transactionId = adjustEvent.transactionId; + string callbackId = adjustEvent.callbackId; + string stringJsonCallbackParameters = AdjustUtils.ConvertListToJson(adjustEvent.callbackList); + string stringJsonPartnerParameters = AdjustUtils.ConvertListToJson(adjustEvent.partnerList); + + _AdjustTrackEvent(eventToken, revenue, currency, receipt, transactionId, callbackId, isReceiptSet, stringJsonCallbackParameters, stringJsonPartnerParameters); + } + + public static void SetEnabled(bool enabled) + { + _AdjustSetEnabled(AdjustUtils.ConvertBool(enabled)); + } + + public static bool IsEnabled() + { + var iIsEnabled = _AdjustIsEnabled(); + return Convert.ToBoolean(iIsEnabled); + } + + public static void SetOfflineMode(bool enabled) + { + _AdjustSetOfflineMode(AdjustUtils.ConvertBool(enabled)); + } + + public static void SendFirstPackages() + { + _AdjustSendFirstPackages(); + } + + public static void AppWillOpenUrl(string url) + { + _AdjustAppWillOpenUrl(url); + } + + public static void AddSessionPartnerParameter(string key, string value) + { + _AdjustAddSessionPartnerParameter(key, value); + } + + public static void AddSessionCallbackParameter(string key, string value) + { + _AdjustAddSessionCallbackParameter(key, value); + } + + public static void RemoveSessionPartnerParameter(string key) + { + _AdjustRemoveSessionPartnerParameter(key); + } + + public static void RemoveSessionCallbackParameter(string key) + { + _AdjustRemoveSessionCallbackParameter(key); + } + + public static void ResetSessionPartnerParameters() + { + _AdjustResetSessionPartnerParameters(); + } + + public static void ResetSessionCallbackParameters() + { + _AdjustResetSessionCallbackParameters(); + } + + public static void TrackAdRevenue(string source, string payload) + { + _AdjustTrackAdRevenue(source, payload); + } + + public static void TrackAppStoreSubscription(AdjustAppStoreSubscription subscription) + { + string price = subscription.price; + string currency = subscription.currency; + string transactionId = subscription.transactionId; + string receipt = subscription.receipt; + string billingStore = subscription.billingStore; + string transactionDate = subscription.transactionDate; + string salesRegion = subscription.salesRegion; + string stringJsonCallbackParameters = AdjustUtils.ConvertListToJson(subscription.callbackList); + string stringJsonPartnerParameters = AdjustUtils.ConvertListToJson(subscription.partnerList); + + _AdjustTrackAppStoreSubscription( + price, + currency, + transactionId, + receipt, + billingStore, + transactionDate, + salesRegion, + stringJsonCallbackParameters, + stringJsonPartnerParameters); + } + + public static void TrackThirdPartySharing(AdjustThirdPartySharing thirdPartySharing) + { + int enabled = AdjustUtils.ConvertBool(thirdPartySharing.isEnabled); + List jsonGranularOptions = new List(); + foreach (KeyValuePair> entry in thirdPartySharing.granularOptions) + { + jsonGranularOptions.Add(entry.Key); + jsonGranularOptions.Add(AdjustUtils.ConvertListToJson(entry.Value)); + } + + _AdjustTrackThirdPartySharing(enabled, AdjustUtils.ConvertListToJson(jsonGranularOptions)); + } + + public static void TrackMeasurementConsent(bool enabled) + { + _AdjustTrackMeasurementConsent(AdjustUtils.ConvertBool(enabled)); + } + + public static void RequestTrackingAuthorizationWithCompletionHandler(string sceneName) + { + string cSceneName = sceneName != null ? sceneName : "ADJ_INVALID"; + _AdjustRequestTrackingAuthorizationWithCompletionHandler(cSceneName); + } + + public static void UpdateConversionValue(int conversionValue) + { + _AdjustUpdateConversionValue(conversionValue); + } + + public static int GetAppTrackingAuthorizationStatus() + { + return _AdjustGetAppTrackingAuthorizationStatus(); + } + + public static void SetDeviceToken(string deviceToken) + { + _AdjustSetDeviceToken(deviceToken); + } + + public static string GetIdfa() + { + return _AdjustGetIdfa(); + } + + public static string GetAdid() + { + return _AdjustGetAdid(); + } + + public static string GetSdkVersion() + { + return sdkPrefix + "@" + _AdjustGetSdkVersion(); + } + + public static void GdprForgetMe() + { + _AdjustGdprForgetMe(); + } + + public static void DisableThirdPartySharing() + { + _AdjustDisableThirdPartySharing(); + } + + public static AdjustAttribution GetAttribution() + { + string attributionString = _AdjustGetAttribution(); + if (null == attributionString) + { + return null; + } + + var attribution = new AdjustAttribution(attributionString); + return attribution; + } + + // Used for testing only. + public static void SetTestOptions(Dictionary testOptions) + { + string baseUrl = testOptions[AdjustUtils.KeyTestOptionsBaseUrl]; + string gdprUrl = testOptions[AdjustUtils.KeyTestOptionsGdprUrl]; + string subscriptionUrl = testOptions[AdjustUtils.KeyTestOptionsSubscriptionUrl]; + string extraPath = testOptions.ContainsKey(AdjustUtils.KeyTestOptionsExtraPath) ? testOptions[AdjustUtils.KeyTestOptionsExtraPath] : null; + long timerIntervalMilis = -1; + long timerStartMilis = -1; + long sessionIntMilis = -1; + long subsessionIntMilis = -1; + bool teardown = false; + bool deleteState = false; + bool noBackoffWait = false; + bool iAdFrameworkEnabled = false; + bool adServicesFrameworkEnabled = false; + + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsTimerIntervalInMilliseconds)) + { + timerIntervalMilis = long.Parse(testOptions[AdjustUtils.KeyTestOptionsTimerIntervalInMilliseconds]); + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsTimerStartInMilliseconds)) + { + timerStartMilis = long.Parse(testOptions[AdjustUtils.KeyTestOptionsTimerStartInMilliseconds]); + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsSessionIntervalInMilliseconds)) + { + sessionIntMilis = long.Parse(testOptions[AdjustUtils.KeyTestOptionsSessionIntervalInMilliseconds]); + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsSubsessionIntervalInMilliseconds)) + { + subsessionIntMilis = long.Parse(testOptions[AdjustUtils.KeyTestOptionsSubsessionIntervalInMilliseconds]); + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsTeardown)) + { + teardown = testOptions[AdjustUtils.KeyTestOptionsTeardown].ToLower() == "true"; + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsDeleteState)) + { + deleteState = testOptions[AdjustUtils.KeyTestOptionsDeleteState].ToLower() == "true"; + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsNoBackoffWait)) + { + noBackoffWait = testOptions[AdjustUtils.KeyTestOptionsNoBackoffWait].ToLower() == "true"; + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsiAdFrameworkEnabled)) + { + iAdFrameworkEnabled = testOptions[AdjustUtils.KeyTestOptionsiAdFrameworkEnabled].ToLower() == "true"; + } + if (testOptions.ContainsKey(AdjustUtils.KeyTestOptionsAdServicesFrameworkEnabled)) + { + adServicesFrameworkEnabled = testOptions[AdjustUtils.KeyTestOptionsAdServicesFrameworkEnabled].ToLower() == "true"; + } + + _AdjustSetTestOptions( + baseUrl, + gdprUrl, + subscriptionUrl, + extraPath, + timerIntervalMilis, + timerStartMilis, + sessionIntMilis, + subsessionIntMilis, + AdjustUtils.ConvertBool(teardown), + AdjustUtils.ConvertBool(deleteState), + AdjustUtils.ConvertBool(noBackoffWait), + AdjustUtils.ConvertBool(iAdFrameworkEnabled), + AdjustUtils.ConvertBool(adServicesFrameworkEnabled)); + } + + public static void TrackSubsessionStart(string testingArgument = null) + { + if (testingArgument == "test") + { + _AdjustTrackSubsessionStart(); + } + } + + public static void TrackSubsessionEnd(string testingArgument = null) + { + if (testingArgument == "test") + { + _AdjustTrackSubsessionEnd(); + } + } + } +#endif +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustiOS.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustiOS.cs.meta new file mode 100644 index 00000000..ab29d210 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/Adjust/iOS/AdjustiOS.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e0210f5940cff42e699945b0c5aa4c9b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei.meta new file mode 100644 index 00000000..e07718c8 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a792f5677238c40a18ed05b17bcec4ef +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android.meta new file mode 100644 index 00000000..e00e536b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b83100566660a43e59ed822f9333cd51 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/AdjustImeiAndroid.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/AdjustImeiAndroid.cs new file mode 100755 index 00000000..c3fff376 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/AdjustImeiAndroid.cs @@ -0,0 +1,31 @@ +using System; +using System.Runtime.InteropServices; +using UnityEngine; + +namespace com.adjust.sdk.imei +{ +#if UNITY_ANDROID + public class AdjustImeiAndroid + { + private static AndroidJavaClass ajcAdjustImei = new AndroidJavaClass("com.adjust.sdk.imei.AdjustImei"); + + public static void ReadImei() + { + if (ajcAdjustImei == null) + { + ajcAdjustImei = new AndroidJavaClass("com.adjust.sdk.imei.AdjustImei"); + } + ajcAdjustImei.CallStatic("readImei"); + } + + public static void DoNotReadImei() + { + if (ajcAdjustImei == null) + { + ajcAdjustImei = new AndroidJavaClass("com.adjust.sdk.imei.AdjustImei"); + } + ajcAdjustImei.CallStatic("doNotReadImei"); + } + } +#endif +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/AdjustImeiAndroid.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/AdjustImeiAndroid.cs.meta new file mode 100755 index 00000000..346cffcf --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/AdjustImeiAndroid.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: bb2d8d10c00a1450988aeccf4a105d3e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/adjust-android-imei.jar b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/adjust-android-imei.jar new file mode 100755 index 00000000..c6222ac1 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/adjust-android-imei.jar differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/adjust-android-imei.jar.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/adjust-android-imei.jar.meta new file mode 100755 index 00000000..e845e3f0 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Android/adjust-android-imei.jar.meta @@ -0,0 +1,29 @@ +fileFormatVersion: 2 +guid: eb5e2f7159b0f4a539f69aedcc295a97 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + Android: Android + second: + enabled: 1 + settings: {} + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor.meta new file mode 100644 index 00000000..6cdfb3de --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 40f47c6037fe841509999a1469821d4c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor/AdjustImeiEditor.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor/AdjustImeiEditor.cs new file mode 100644 index 00000000..5daa6373 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor/AdjustImeiEditor.cs @@ -0,0 +1,264 @@ +using System; +using System.IO; +using System.Xml; +using System.Collections; +using System.Collections.Generic; +using System.Diagnostics; +using System.Text.RegularExpressions; +using UnityEngine; +using UnityEditor; +using UnityEditor.Callbacks; + +public class AdjustImeiEditor +{ + private const string MenuItem0 = "Assets/AdjustImei/Is my app properly configured?"; + private const string MenuItem1 = "Assets/AdjustImei/Autorun post-build tasks"; + private const string MenuItem2 = "Assets/AdjustImei/Run post-build tasks"; + private const string MenuItem3 = "Assets/AdjustImei/Export Unity package"; + + private static bool shouldAutorun = true; + + static AdjustImeiEditor() + { + EditorApplication.delayCall += () => + { + shouldAutorun = EditorPrefs.GetBool(MenuItem1, true); + Menu.SetChecked(MenuItem1, shouldAutorun); + }; + } + + [MenuItem(MenuItem0)] + static void IsAppProperlyConfigured() + { + bool isProperlyConfigured = DoesAppHaveAllThePermissions(); + if (isProperlyConfigured) + { + EditorUtility.DisplayDialog("Adjust IMEI Plugin", "Your app is properly configured for usage of the Adjust IMEI plugin.", "OK"); + } + else + { + EditorUtility.DisplayDialog("AdjustImei", "Your app is NOT properly configured for usage of the Adjust IMEI plugin." + + "\n\nPlease perform one of the following tasks: " + + " \n\n- Enable \"Autorun post-build tasks\" option from the menu and rebuild your app." + + " \n- Select \"Run post-build tasks\" option from the menu." + + "\n\nAfter that re-run this check to make sure you app is properly configured.", "OK"); + } + } + + [MenuItem(MenuItem1)] + static void AutorunPostBuildTasks() + { + shouldAutorun = !shouldAutorun; + Menu.SetChecked(MenuItem1, shouldAutorun); + EditorPrefs.SetBool(MenuItem1, shouldAutorun); + + if (shouldAutorun) + { + EditorUtility.DisplayDialog("Adjust IMEI Plugin", "Adjust IMEI plugin post build tasks will from now on be performed each time you build your app.", "OK"); + } + else + { + EditorUtility.DisplayDialog("Adjust IMEI Plugin", "Adjust IMEI plugin post build tasks from now on WON’T be performed each time you build your app." + + "\n\nPlease, make sure that your app is compatible for usage of the Adjust IMEI plugin by selecting \"Is my app properly configured?\" option from menu.", "OK"); + } + } + + [MenuItem(MenuItem2)] + static void RunPostBuildTasksManually() + { + RunPostBuildScript(BuildTarget.Android, false); + EditorUtility.DisplayDialog("Adjust IMEI Plugin", "Post-build tasks execution completed." + + "\n\nPlease, make sure that your app is compatible for usage of the Adjust IMEI plugin by selecting \"Is my app properly configured?\" option from menu.", "OK"); + } + + [MenuItem(MenuItem3)] + static void ExportAdjustUnityPackage() + { + string exportedFileName = "AdjustImei.unitypackage"; + string assetsPath = "Assets/AdjustImei"; + List assetsToExport = new List(); + + assetsToExport.Add(assetsPath + "/Android/adjust-android-imei.jar"); + assetsToExport.Add(assetsPath + "/Android/AdjustImeiAndroid.cs"); + assetsToExport.Add(assetsPath + "/Editor/AdjustImeiEditor.cs"); + assetsToExport.Add(assetsPath + "/Prefab/AdjustImei.prefab"); + assetsToExport.Add(assetsPath + "/Unity/AdjustImei.cs"); + + AssetDatabase.ExportPackage( + assetsToExport.ToArray(), + exportedFileName, + ExportPackageOptions.IncludeDependencies | ExportPackageOptions.Interactive); + } + + [PostProcessBuild(3)] + public static void OnPostprocessBuild(BuildTarget target, string projectPath) + { + RunPostBuildScript(target: target, preBuild: false, projectPath: projectPath); + } + + private static void RunPostBuildScript(BuildTarget target, bool preBuild, string projectPath = "") + { + if (target == BuildTarget.Android) + { + UnityEngine.Debug.Log("[AdjustImei]: Starting to perform post build tasks for Android platform."); + RunPostProcessTasksAndroid(); + } + } + + private static void RunPostProcessTasksAndroid() + { + string appManifestPath = Path.Combine(Application.dataPath, "Plugins/Android/AndroidManifest.xml"); + + // Check if user has already created AndroidManifest.xml file in its location. + // If not, do nothing until user has valid AndroidManifest.xml file in place. + if (!File.Exists(appManifestPath)) + { + UnityEngine.Debug.Log("[AdjustImei]: User defined AndroidManifest.xml file not found in Plugins/Android folder."); + UnityEngine.Debug.Log("[AdjustImei]: Aborting post build tasks. Please make sure you have valid AndroidManifest.xml file in place and rebuild your app."); + return; + } + else + { + UnityEngine.Debug.Log("[AdjustImei]: User defined AndroidManifest.xml file located in Plugins/Android folder."); + } + + // Seems like you already have your own AndroidManifest.xml, we’ll now run + // some checks on it and tweak it a bit if needed to add some stuff which + // our native Android IMEI plugin needs so that it can run properly. + + // Let’s open the app’s AndroidManifest.xml file. + XmlDocument manifestFile = new XmlDocument(); + manifestFile.Load(appManifestPath); + + bool manifestHasChanged = false; + + // Add needed permissions if they are missing. + manifestHasChanged |= AddPermissions(manifestFile); + + if (manifestHasChanged) + { + // Save the changes. + manifestFile.Save(appManifestPath); + + // Clean the manifest file. + CleanManifestFile(appManifestPath); + + UnityEngine.Debug.Log("[AdjustImei]: App’s AndroidManifest.xml file check and potential modification completed."); + UnityEngine.Debug.Log("[AdjustImei]: Please check if any error message was displayed during this process " + + "and make sure to fix all issues in order to properly use the Adjust IMEI plugin in your app."); + } + else + { + UnityEngine.Debug.Log("[AdjustImei]: App’s AndroidManifest.xml file check completed."); + UnityEngine.Debug.Log("[AdjustImei]: No modifications performed due to app’s AndroidManifest.xml file compatibility."); + } + } + + private static bool AddPermissions(XmlDocument manifest) + { + // The Adjust IMEI plugin needs following permissions to be added to you app’s manifest file: + // + + UnityEngine.Debug.Log("[AdjustImei]: Checking if all permissions needed for the Adjust IMEI plugin are present in the app’s AndroidManifest.xml file."); + + bool hasReadPhoneStatePermission = false; + XmlElement manifestRoot = manifest.DocumentElement; + + // Check if permissions are already there. + foreach (XmlNode node in manifestRoot.ChildNodes) + { + if (node.Name == "uses-permission") + { +#if CN + foreach (XmlAttribute attribute in node.Attributes) + { + + if (attribute.Value.Contains("android.permission.READ_PHONE_STATE")) + { + hasReadPhoneStatePermission = true; + } + + } +#endif + } + } + + bool manifestHasChanged = false; + + // If android.permission.READ_PHONE_STATE permission is missing, add it. + if (!hasReadPhoneStatePermission) + { +#if CN + XmlElement element = manifest.CreateElement("uses-permission"); + element.SetAttribute("android__name", "android.permission.READ_PHONE_STATE"); + manifestRoot.AppendChild(element); + UnityEngine.Debug.Log("[AdjustImei]: android.permission.READ_PHONE_STATE permission successfully added to your app’s AndroidManifest.xml file."); + manifestHasChanged = true; +#endif + } + else + { + UnityEngine.Debug.Log("[AdjustImei]: Your app’s AndroidManifest.xml file already contains android.permission.READ_PHONE_STATE permission."); + UnityEngine.Debug.Log("[AdjustImei]: All good."); + } + + return manifestHasChanged; + } + + private static void CleanManifestFile(String manifestPath) + { + // Due to XML writing issue with XmlElement methods which are unable + // to write "android:[param]" string, we have wrote "android__[param]" string instead. + // Now make the replacement: "android:[param]" -> "android__[param]" + + TextReader manifestReader = new StreamReader(manifestPath); + string manifestContent = manifestReader.ReadToEnd(); + manifestReader.Close(); + + Regex regex = new Regex("android__"); + manifestContent = regex.Replace(manifestContent, "android:"); + + TextWriter manifestWriter = new StreamWriter(manifestPath); + manifestWriter.Write(manifestContent); + manifestWriter.Close(); + } + + private static bool DoesAppHaveAllThePermissions() + { + string appManifestPath = Path.Combine(Application.dataPath, "Plugins/Android/AndroidManifest.xml"); + + // Check if user has already created AndroidManifest.xml file in its location. + // If not, do nothing until user has valid AndroidManifest.xml file in place. + if (!File.Exists(appManifestPath)) + { + return false; + } + + // Seems like you already have your own AndroidManifest.xml. + // We’ll now check if all the permissions needed by the plugin are added. + + // Let’s open the app’s AndroidManifest.xml file. + XmlDocument manifestFile = new XmlDocument(); + manifestFile.Load(appManifestPath); + + // Check for the android.permission.READ_PHONE_STATE permission. + XmlElement manifestRoot = manifestFile.DocumentElement; + foreach (XmlNode node in manifestRoot.ChildNodes) + { + if (node.Name == "uses-permission") + { +#if CN + foreach (XmlAttribute attribute in node.Attributes) + { + if (attribute.Value.Contains("android.permission.READ_PHONE_STATE")) + { + return true; + } + } +#endif + } + } + + return false; + } +} \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor/AdjustImeiEditor.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor/AdjustImeiEditor.cs.meta new file mode 100755 index 00000000..5f9b0350 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Editor/AdjustImeiEditor.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b7de5893387fd40d0b55f679765b7ac7 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab.meta new file mode 100644 index 00000000..40b32acf --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ad8048fb22a0f4e019e68fa804cef510 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab/AdjustImei.prefab b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab/AdjustImei.prefab new file mode 100755 index 00000000..0c76314e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab/AdjustImei.prefab @@ -0,0 +1,55 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &115478 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 415478} + - component: {fileID: 114479779628156014} + m_Layer: 0 + m_Name: AdjustImei + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &415478 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115478} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 115478} + m_IsPrefabParent: 1 +--- !u!114 &114479779628156014 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115478} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 964407eb654c2401caf826ceabb3bab1, type: 3} + m_Name: + m_EditorClassIdentifier: + startManually: 1 + readImei: 0 diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab/AdjustImei.prefab.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab/AdjustImei.prefab.meta new file mode 100755 index 00000000..158a9108 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Prefab/AdjustImei.prefab.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 0a039a49531864696b1b1297a0baba06 +timeCreated: 1565087930 +licenseType: Pro +NativeFormatImporter: + mainObjectFileID: -1 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity.meta new file mode 100644 index 00000000..3d90f85c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 34565d45792f14650bfa5ee1ba2d1907 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity/AdjustImei.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity/AdjustImei.cs new file mode 100755 index 00000000..cc09a593 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity/AdjustImei.cs @@ -0,0 +1,65 @@ +using System; +using UnityEngine; + +namespace com.adjust.sdk.imei +{ + public class AdjustImei : MonoBehaviour + { + private const string errorMsgEditor = "[AdjustImei]: Adjust IMEI plugin can not be used in Editor."; + private const string errorMsgPlatform = "[AdjustImei]: Adjust IMEI plugin can only be used in Android apps."; + + public bool startManually = true; + public bool readImei = false; + + void Awake() + { + if (IsEditor()) { return; } + + DontDestroyOnLoad(transform.gameObject); + + if (!this.startManually) + { + if (this.readImei) + { + AdjustImei.ReadImei(); + } + else + { + AdjustImei.DoNotReadImei(); + } + } + } + + public static void ReadImei() + { + if (IsEditor()) { return; } + +#if UNITY_ANDROID + AdjustImeiAndroid.ReadImei(); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void DoNotReadImei() + { + if (IsEditor()) { return; } + +#if UNITY_ANDROID + AdjustImeiAndroid.DoNotReadImei(); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + private static bool IsEditor() + { +#if UNITY_EDITOR + Debug.Log(errorMsgEditor); + return true; +#else + return false; +#endif + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity/AdjustImei.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity/AdjustImei.cs.meta new file mode 100755 index 00000000..cba90571 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustImei/Unity/AdjustImei.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 964407eb654c2401caf826ceabb3bab1 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid.meta new file mode 100644 index 00000000..411daa5f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bc79db9cdbcfa4382a2f2dadf699ec42 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android.meta new file mode 100644 index 00000000..0e0bcf07 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 69682c4196d3a45288efbe063d47833d +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/AdjustOaidAndroid.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/AdjustOaidAndroid.cs new file mode 100755 index 00000000..ffbce0bc --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/AdjustOaidAndroid.cs @@ -0,0 +1,32 @@ +using System; +using System.Runtime.InteropServices; +using UnityEngine; + +namespace com.adjust.sdk.oaid +{ +#if UNITY_ANDROID + public class AdjustOaidAndroid + { + private static AndroidJavaClass ajcAdjustOaid = new AndroidJavaClass("com.adjust.sdk.oaid.AdjustOaid"); + private static AndroidJavaObject ajoCurrentActivity = new AndroidJavaClass("com.unity3d.player.UnityPlayer").GetStatic("currentActivity"); + + public static void ReadOaid() + { + if (ajcAdjustOaid == null) + { + ajcAdjustOaid = new AndroidJavaClass("com.adjust.sdk.oaid.AdjustOaid"); + } + ajcAdjustOaid.CallStatic("readOaid", ajoCurrentActivity); + } + + public static void DoNotReadOaid() + { + if (ajcAdjustOaid == null) + { + ajcAdjustOaid = new AndroidJavaClass("com.adjust.sdk.oaid.AdjustOaid"); + } + ajcAdjustOaid.CallStatic("doNotReadOaid"); + } + } +#endif +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/AdjustOaidAndroid.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/AdjustOaidAndroid.cs.meta new file mode 100755 index 00000000..b4f516c6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/AdjustOaidAndroid.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: a5159acf47e3b4d8da5d621e07119b2c +timeCreated: 1569414346 +licenseType: Pro +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/adjust-android-oaid.jar b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/adjust-android-oaid.jar new file mode 100755 index 00000000..ee07e0ef Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/adjust-android-oaid.jar differ diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/adjust-android-oaid.jar.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/adjust-android-oaid.jar.meta new file mode 100755 index 00000000..36f9becd --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Android/adjust-android-oaid.jar.meta @@ -0,0 +1,33 @@ +fileFormatVersion: 2 +guid: f4e298717a1d64cdea4c0904aa08c836 +timeCreated: 1569414347 +licenseType: Pro +PluginImporter: + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + data: + first: + Android: Android + second: + enabled: 1 + settings: {} + data: + first: + Any: + second: + enabled: 0 + settings: {} + data: + first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor.meta new file mode 100644 index 00000000..f02ddc2f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 642338a5c45044829a2082db0785ce16 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor/AdjustOaidEditor.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor/AdjustOaidEditor.cs new file mode 100755 index 00000000..2fceb35e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor/AdjustOaidEditor.cs @@ -0,0 +1,64 @@ +using System; +using System.IO; +using System.Xml; +using System.Collections; +using System.Collections.Generic; +using System.Diagnostics; +using System.Text.RegularExpressions; +using UnityEngine; +using UnityEditor; +using UnityEditor.Callbacks; + +public class AdjustOaidEditor +{ + private const string MenuItem0 = "Assets/AdjustOaid/Autorun post-build tasks"; + private const string MenuItem1 = "Assets/AdjustOaid/Export Unity package"; + + private static bool shouldAutorun = true; + + static AdjustOaidEditor() + { + EditorApplication.delayCall += () => + { + shouldAutorun = EditorPrefs.GetBool(MenuItem0, true); + Menu.SetChecked(MenuItem0, shouldAutorun); + }; + } + + [MenuItem(MenuItem0)] + static void AutorunPostBuildTasks() + { + shouldAutorun = !shouldAutorun; + Menu.SetChecked(MenuItem0, shouldAutorun); + EditorPrefs.SetBool(MenuItem0, shouldAutorun); + + if (shouldAutorun) + { + EditorUtility.DisplayDialog("Adjust OAID Plugin", "Adjust OAID plugin post build tasks will from now on be performed each time you build your app.", "OK"); + } + else + { + EditorUtility.DisplayDialog("Adjust OAID Plugin", "Adjust OAID plugin post build tasks from now on WON'T be performed each time you build your app." + + "\n\nPlease, make sure that your app is compatible for usage of the Adjust OAID plugin by selecting \"Is my app properly configured?\" option from menu.", "OK"); + } + } + + [MenuItem(MenuItem1)] + static void ExportAdjustUnityPackage() + { + string exportedFileName = "AdjustOaid.unitypackage"; + string assetsPath = "Assets/AdjustOaid"; + List assetsToExport = new List(); + + assetsToExport.Add(assetsPath + "/Android/adjust-android-oaid.jar"); + assetsToExport.Add(assetsPath + "/Android/AdjustOaidAndroid.cs"); + assetsToExport.Add(assetsPath + "/Editor/AdjustOaidEditor.cs"); + assetsToExport.Add(assetsPath + "/Prefab/AdjustOaid.prefab"); + assetsToExport.Add(assetsPath + "/Unity/AdjustOaid.cs"); + + AssetDatabase.ExportPackage( + assetsToExport.ToArray(), + exportedFileName, + ExportPackageOptions.IncludeDependencies | ExportPackageOptions.Interactive); + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor/AdjustOaidEditor.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor/AdjustOaidEditor.cs.meta new file mode 100755 index 00000000..b3f637e6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Editor/AdjustOaidEditor.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 43bcb111f6b23480ea76cca51e22444d +timeCreated: 1569414346 +licenseType: Pro +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab.meta new file mode 100644 index 00000000..da09134f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: aabef322304024472b0c9f590fe0e0b2 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab/AdjustOaid.prefab b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab/AdjustOaid.prefab new file mode 100755 index 00000000..5ad83afe --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab/AdjustOaid.prefab @@ -0,0 +1,55 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &115478 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 415478} + - component: {fileID: 114943227175462948} + m_Layer: 0 + m_Name: AdjustOaid + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &415478 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115478} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 115478} + m_IsPrefabParent: 1 +--- !u!114 &114943227175462948 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115478} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 97f6fe126cade4bf29d7be90110b1ca3, type: 3} + m_Name: + m_EditorClassIdentifier: + startManually: 1 + readOaid: 0 diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab/AdjustOaid.prefab.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab/AdjustOaid.prefab.meta new file mode 100755 index 00000000..96c0e409 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Prefab/AdjustOaid.prefab.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 6ad2bb468bdd644e5a2a90e459811df9 +timeCreated: 1569414347 +licenseType: Pro +NativeFormatImporter: + mainObjectFileID: -1 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity.meta new file mode 100644 index 00000000..dc706cc4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ca7c79a15b977404ba40882d9d6a9b88 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity/AdjustOaid.cs b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity/AdjustOaid.cs new file mode 100755 index 00000000..1bc410a9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity/AdjustOaid.cs @@ -0,0 +1,65 @@ +using System; +using UnityEngine; + +namespace com.adjust.sdk.oaid +{ + public class AdjustOaid : MonoBehaviour + { + private const string errorMsgEditor = "[AdjustOaid]: Adjust OAID plugin can not be used in Editor."; + private const string errorMsgPlatform = "[AdjustOaid]: Adjust OAID plugin can only be used in Android apps."; + + public bool startManually = true; + public bool readOaid = false; + + void Awake() + { + if (IsEditor()) { return; } + + DontDestroyOnLoad(transform.gameObject); + + if (!this.startManually) + { + if (this.readOaid) + { + AdjustOaid.ReadOaid(); + } + else + { + AdjustOaid.DoNotReadOaid(); + } + } + } + + public static void ReadOaid() + { + if (IsEditor()) { return; } + +#if UNITY_ANDROID + AdjustOaidAndroid.ReadOaid(); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + public static void DoNotReadOaid() + { + if (IsEditor()) { return; } + +#if UNITY_ANDROID + AdjustOaidAndroid.DoNotReadOaid(); +#else + Debug.Log(errorMsgPlatform); +#endif + } + + private static bool IsEditor() + { +#if UNITY_EDITOR + Debug.Log(errorMsgEditor); + return true; +#else + return false; +#endif + } + } +} diff --git a/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity/AdjustOaid.cs.meta b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity/AdjustOaid.cs.meta new file mode 100755 index 00000000..782325c9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Ga_Adjust/AdjustOaid/Unity/AdjustOaid.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 97f6fe126cade4bf29d7be90110b1ca3 +timeCreated: 1569414346 +licenseType: Pro +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/JoyPacAd.meta b/popcorn/Assets/JoyPacSDK/JoyPacAd.meta new file mode 100644 index 00000000..64c1fa49 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/JoyPacAd.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b889232e96f5e4016b375f33828e02f8 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Resources.meta b/popcorn/Assets/JoyPacSDK/Resources.meta new file mode 100644 index 00000000..a11feea0 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Resources.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dffeb3db740264488852e4eaca0d80d0 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Resources/JoyPacBuildParams.asset b/popcorn/Assets/JoyPacSDK/Resources/JoyPacBuildParams.asset new file mode 100644 index 00000000..63567d83 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Resources/JoyPacBuildParams.asset @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 6d485789450d49d68846cd7ed916ed63, type: 3} + m_Name: JoyPacBuildParams + m_EditorClassIdentifier: + iOSCN_productName: + iOSCN_bundleVersion: + iOSCN_BundleID: + iOSCN_Automaticall_Sign: 0 + iOSCN_DeveloperTeamID: + iOSOS_productName: + iOSOS_bundleVersion: + iOSOS_BundleID: + iOSOS_Automaticall_Sign: 0 + iOSOS_DeveloperTeamID: + AndroidOS_productName: + AndroidOS_bundleVersion: + AndroidOS_BundleID: diff --git a/popcorn/Assets/JoyPacSDK/Resources/JoyPacBuildParams.asset.meta b/popcorn/Assets/JoyPacSDK/Resources/JoyPacBuildParams.asset.meta new file mode 100644 index 00000000..873e96f8 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Resources/JoyPacBuildParams.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 62b4402cb229c4fe59c1f003d4bf2248 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 11400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Resources/JoyPacParams.asset b/popcorn/Assets/JoyPacSDK/Resources/JoyPacParams.asset new file mode 100644 index 00000000..13fbc364 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Resources/JoyPacParams.asset @@ -0,0 +1,96 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: edf2b10a78afa4801a0ccced23ab711d, type: 3} + m_Name: JoyPacParams + m_EditorClassIdentifier: + iOS_jPReleaseAreaType: 1 + Android_jPReleaseAreaType: 2 + iOSCN_AdjustDeeplink: + iOSCN_ADJUST_APP_TOKEN: gtc62c0h5ngg + iOSCN_GA_gameKey: ca486def04a25e8dbdfa18b89f81e1d7 + iOSCN_GA_secretKey: 588c7560ca0b372017b1cfc7286e0e683313b2ea + iOSCN_IsHaveAdjustEvent: 0 + iOSCN_DEVICEINFO_IPAD_TOKEN: + iOSCN_DEVICEINFO_IPHONE_TOKEN: + iOSCN_INTERSITIAL_SHOW_COUNT_TOKEN: + iOSCN_SECOND_LAUNCH_DAY_TOKEN: + iOSCN_VIDEO_SHOW_COUNT_TOKEN: + iOSCN_ADJUST_EVENT_RVIV24: + iOSCN_ADJUST_EVENT_RV24: + iOSOS_AdjustDeeplink: + iOSOS_ADJUST_APP_TOKEN: + iOSOS_GA_gameKey: + iOSOS_GA_secretKey: + iOSOS_IsHaveAdjustEvent: 0 + iOSOS_DEVICEINFO_IPAD_TOKEN: + iOSOS_DEVICEINFO_IPHONE_TOKEN: + iOSOS_INTERSITIAL_SHOW_COUNT_TOKEN: + iOSOS_SECOND_LAUNCH_DAY_TOKEN: + iOSOS_VIDEO_SHOW_COUNT_TOKEN: + iOSOS_ADJUST_EVENT_RVIV24: + iOSOS_ADJUST_EVENT_RV24: + iOSCN_IsHaveAppraise: 0 + iOSCN_APPLE_APP_ID: + iOSOS_IsHaveAppraise: 0 + iOSOS_APPLE_APP_ID: + iOSCN_JoypacAppName: "\u5C0F\u9E21\u7206\u7C73\u82B1" + iOSCN_JOYPAC_SDK_APPID: 14c99a9072 + iOSCN_PrivacyURL: https://joypacgames.com/zh-hant/privacy-policy/ + iOSCN_ProtocolURL: https://joypacgames.com/zh-hant/terms-conditions/ + iOSCN_GameName: "\u5C0F\u9E21\u5144\u5F1F\u7684\u7206\u7C73\u82B1\u5E97\u94FA" + iOSCN_GameType: "\u6A21\u62DF\u7ECF\u8425\u7C7B" + iOSOS_JoypacAppName: + iOSOS_JOYPAC_SDK_APPID: + iOSCN_UMENG_APPKEY: 62172e13ddf2ea630e461df4 + iOSCN_UMENG_CHANNELID: AppStore + iOSOS_UMENG_APPKEY: + iOSOS_UMENG_CHANNELID: AppStore + AttEnabled: 0 + iOSCN_Admob_GADApplicationIdentifier: ca-app-pub-1310074477383748~1386535025 + iOSCN_AppLovinSdkKey: MziT8gS2aacKcumsF6qUd7ZPa1xoZ07xzqT5Vx84WlP8dA-tGpMvwwIVyEIVEPRCEwIksQpMADVoNUfdH0WCxq + iOSOS_Admob_GADApplicationIdentifier: + iOSOS_AppLovinSdkKey: + PushEnabled: 0 + AndroidOS_AdjustDeeplink: + AndroidOS_ADJUST_APP_TOKEN: + AndroidOS_GA_gameKey: + AndroidOS_GA_secretKey: + AndroidOS_IsHaveAdjustEvent: 0 + AndroidOS_DEVICEINFO_IPAD_TOKEN: + AndroidOS_DEVICEINFO_IPHONE_TOKEN: + AndroidOS_INTERSITIAL_SHOW_COUNT_TOKEN: + AndroidOS_SECOND_LAUNCH_DAY_TOKEN: + AndroidOS_VIDEO_SHOW_COUNT_TOKEN: + AndroidOS_ADJUST_EVENT_RVIV24: + AndroidOS_ADJUST_EVENT_RV24: + AndroidCN_AdjustDeeplink: + AndroidCN_ADJUST_APP_TOKEN: + AndroidCN_GA_gameKey: + AndroidCN_GA_secretKey: + AndroidCN_IsHaveAdjustEvent: 0 + AndroidCN_DEVICEINFO_IPAD_TOKEN: + AndroidCN_DEVICEINFO_IPHONE_TOKEN: + AndroidCN_INTERSITIAL_SHOW_COUNT_TOKEN: + AndroidCN_SECOND_LAUNCH_DAY_TOKEN: + AndroidCN_VIDEO_SHOW_COUNT_TOKEN: + AndroidCN_ADJUST_EVENT_RVIV24: + AndroidCN_ADJUST_EVENT_RV24: + AndroidOS_JoypacAppName: + AndroidOS_JOYPAC_SDK_APPID: + AndroidCN_JoypacAppName: + AndroidCN_JOYPAC_SDK_APPID: + AndroidOS_UMENG_APPKEY: + AndroidOS_UMENG_CHANNELID: googleplay + AndroidOS_Admob_GADApplicationIdentifier: + app_setting_name: + app_settting_def_key: + splash_orientation_key: diff --git a/popcorn/Assets/JoyPacSDK/Resources/JoyPacParams.asset.meta b/popcorn/Assets/JoyPacSDK/Resources/JoyPacParams.asset.meta new file mode 100644 index 00000000..c68abeb4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Resources/JoyPacParams.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2e11ea0574319424992b4daaea48769f +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 11400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng.meta b/popcorn/Assets/JoyPacSDK/Umeng.meta new file mode 100644 index 00000000..ece58103 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 613c4dfee40b44df8bf8c3d400c2a785 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins.meta new file mode 100644 index 00000000..62c5bec4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d0811a3543dc2420a92ee798a32e5a34 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS.meta new file mode 100644 index 00000000..d0c5ef49 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7109e2e1a3fae445584e6cf52221c5f5 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK.meta new file mode 100644 index 00000000..25560248 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 382c3387461b540399af9a8c0ea286e9 +folderAsset: yes +timeCreated: 1554692913 +licenseType: Pro +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK/libUMUnityAnalytics.a b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK/libUMUnityAnalytics.a new file mode 100755 index 00000000..f55ba8d8 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK/libUMUnityAnalytics.a differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK/libUMUnityAnalytics.a.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK/libUMUnityAnalytics.a.meta new file mode 100644 index 00000000..8fe4cd50 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/CSSDK/libUMUnityAnalytics.a.meta @@ -0,0 +1,32 @@ +fileFormatVersion: 2 +guid: 83bc7b6e3569a42d09aefa11334cf1c4 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm.meta new file mode 100644 index 00000000..e673c472 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f1be65bee28c7493b97236c02315fb95 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0.meta new file mode 100644 index 00000000..2ba37e2e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5e0000e9834234228afe8d3f7fb7d453 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework.meta new file mode 100644 index 00000000..256721c2 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 5fc01d26f265240159ad8ce5b28f1c7b +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers.meta new file mode 100644 index 00000000..64bb4911 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 86b37e70db2f241d5a7bc2c6bdd98796 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMAPMConfig.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMAPMConfig.h new file mode 100644 index 00000000..acebaf3b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMAPMConfig.h @@ -0,0 +1,44 @@ +// +// UMAPMConfig.h +// UMAPM +// +// Created by zhangjunhua on 2021/6/21. +// Copyright © 2021 wangkai. All rights reserved. +// + +#import + +NS_ASSUME_NONNULL_BEGIN + +@interface UMAPMConfig : NSObject + + + ++(UMAPMConfig*)defaultConfig; + +/** + * crash&卡顿监控开关,默认开启 + */ +@property (nonatomic,assign) BOOL crashAndBlockMonitorEnable; + + +/** + * 启动模块监控开关,默认开启 + */ +@property (nonatomic,assign) BOOL launchMonitorEnable; + + +/** + * 内存模块监控开关,默认开启 + */ +@property (nonatomic,assign) BOOL memMonitorEnable; + + +/** + * OOM模块监控开关,默认开启 + */ +@property (nonatomic,assign) BOOL oomMonitorEnable; + +@end + +NS_ASSUME_NONNULL_END diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMAPMConfig.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMAPMConfig.h.meta new file mode 100644 index 00000000..217fe8b9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMAPMConfig.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 39ea51c082d6c40d3a07e248d4b999ad +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMCrashConfigure.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMCrashConfigure.h new file mode 100644 index 00000000..d7af823b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMCrashConfigure.h @@ -0,0 +1,33 @@ +// +// UMCrashConfigure.h +// UMCrash +// +// Created by wangkai on 2020/9/3. +// Copyright © 2020 wangkai. All rights reserved. +// + +#import +typedef NSString *_Nullable(^CallbackBlock)(void); +@class UMAPMConfig; + +@interface UMCrashConfigure : NSObject +//获取sdk版本号 ++ (NSString *_Nonnull)getVersion; + +//return字符串不能大于256字节,大于部分将被截取 ++ (void)setCrashCBBlock:(CallbackBlock _Nullable )cbBlock; + + +/** + * 设置自定义版本号和build版本号即子版本号 (需要在初始化appkey方法之前调用) + */ ++ (void)setAppVersion:( NSString * __nonnull )appVersion buildVersion:(NSString* __nullable)buildVersion; + + +/** + * 设置APM的各个模块的开启/关闭配置(需要在初始化appkey方法之前调用) + */ ++(void)setAPMConfig:(UMAPMConfig*_Nonnull)config; + +@end + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMCrashConfigure.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMCrashConfigure.h.meta new file mode 100644 index 00000000..7d1dac1c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMCrashConfigure.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: a76ea062881cb43a4941daff6fc61b65 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMLaunch.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMLaunch.h new file mode 100644 index 00000000..8596cd0b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMLaunch.h @@ -0,0 +1,47 @@ +// +// UMLaunch.h +// WPKCore +// +// Created by zhangjunhua on 2021/4/20. +// Copyright © 2021 uc. All rights reserved. +// + +#import + +NS_ASSUME_NONNULL_BEGIN + +//冷启动的预定义类型 +typedef NS_ENUM(NSInteger,UMPredefineLaunchType){ + UMPredefineLaunchType_DidFinishLaunchingEnd,//在didFinishLaunchingWithOptions的最后一句设置 + UMPredefineLaunchType_ViewDidLoadEnd,//在第一个ViewController的viewDidLoad函数的最后调用 + UMPredefineLaunchType_ViewDidAppearEnd//在第一个ViewController的viewDidAppear函数的最后调用 +}; + +@interface UMLaunch : NSObject + ++(instancetype)shareInstance; + ++(void)setRootVCCls:(Class)cls;//在DidFinishLaunching第一句代码提前设置RootViewController + +/* + * 手动设置三个预定义时间结束时间(初始化耗时结束,应用构建耗时结束,页面加载耗时结束) + */ ++(void)setPredefineLaunchType:(UMPredefineLaunchType)predefineLaunchType; + + +/* + * 用户在冷启动阶段设置自己的自定义阶段 + * @note beginLaunch和endLaunch必须要配对调用 + * 如果调用时间段,不在页面加载耗时结束前调用,是不会上报的 + */ ++ (void)beginLaunch:(NSString *)methodName; ++ (void)endLaunch:(NSString *)methodName; + + +/* + * 开启关闭启动模块采集 + */ ++(void)setLaunchEnable:(BOOL)enable; +@end + +NS_ASSUME_NONNULL_END diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMLaunch.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMLaunch.h.meta new file mode 100644 index 00000000..81eb33a6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Headers/UMLaunch.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 0a5dcd4294f4f45dc99a55052bb054b0 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Info.plist b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Info.plist new file mode 100644 index 00000000..e2c7a20e Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Info.plist differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Info.plist.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Info.plist.meta new file mode 100644 index 00000000..1eb72d73 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/Info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 8be78d7c8c540469cb0c0ffddae430b8 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/UMAPM b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/UMAPM new file mode 100644 index 00000000..22de8f7a Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/UMAPM differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/UMAPM.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/UMAPM.meta new file mode 100644 index 00000000..ecd84e5b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/apm/apm_ios_1.4.0/UMAPM.framework/UMAPM.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: b4959881b5cbf4b1085eb099ec9bed6c +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common.meta new file mode 100644 index 00000000..dcab8ea6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4144b9128eb0e4fc3959e9a9f9179d4a +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3.meta new file mode 100644 index 00000000..859eb0a5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fe7c359a5cabb4bdca87785cabfba360 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework.meta new file mode 100644 index 00000000..92c8e4e4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 014445dc89d1b47a6b41ab496a59971b +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/7.3.3_b183a3c581_20210716163524 b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/7.3.3_b183a3c581_20210716163524 new file mode 100644 index 00000000..44e98ada --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/7.3.3_b183a3c581_20210716163524 @@ -0,0 +1 @@ +7.3.3 diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/7.3.3_b183a3c581_20210716163524.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/7.3.3_b183a3c581_20210716163524.meta new file mode 100644 index 00000000..87ee4f10 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/7.3.3_b183a3c581_20210716163524.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 79888988a2a974883939ead45dc2de25 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers.meta new file mode 100644 index 00000000..87c129a6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d5076a832f8fc4a1ca904044623a9c5d +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/MobClick.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/MobClick.h new file mode 100644 index 00000000..34c39737 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/MobClick.h @@ -0,0 +1,226 @@ +// +// MobClick.h +// Analytics +// +// Copyright (C) 2010-2017 Umeng.com . All rights reserved. + +#import +#import + +@class CLLocation; +@interface MobClick : NSObject + +#pragma mark basics + +///--------------------------------------------------------------------------------------- +/// @name 设置 +///--------------------------------------------------------------------------------------- + + + +#pragma mark event logs +///--------------------------------------------------------------------------------------- +/// @name 页面计时 +///--------------------------------------------------------------------------------------- + +/** 手动页面时长统计, 记录某个页面展示的时长. + @param pageName 统计的页面名称. + @param seconds 单位为秒,int型. + @return void. + */ ++ (void)logPageView:(NSString *)pageName seconds:(int)seconds; + +/** 自动页面时长统计, 开始记录某个页面展示时长. + 使用方法:必须配对调用beginLogPageView:和endLogPageView:两个函数来完成自动统计,若只调用某一个函数不会生成有效数据。 + 在该页面展示时调用beginLogPageView:,当退出该页面时调用endLogPageView: + @param pageName 统计的页面名称. + @return void. + */ ++ (void)beginLogPageView:(NSString *)pageName; + +/** 自动页面时长统计, 结束记录某个页面展示时长. + 使用方法:必须配对调用beginLogPageView:和endLogPageView:两个函数来完成自动统计,若只调用某一个函数不会生成有效数据。 + 在该页面展示时调用beginLogPageView:,当退出该页面时调用endLogPageView: + @param pageName 统计的页面名称. + @return void. + */ ++ (void)endLogPageView:(NSString *)pageName; + + +///--------------------------------------------------------------------------------------- +/// @name 事件统计 +///--------------------------------------------------------------------------------------- + +/** 自定义事件,数量统计. +使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + + @param eventId 网站上注册的事件Id. + @param label 分类标签。不同的标签会分别进行统计,方便同一事件的不同标签的对比,为nil或空字符串时后台会生成和eventId同名的标签. + @param accumulation 累加值。为减少网络交互,可以自行对某一事件ID的某一分类标签进行累加,再传入次数作为参数。 + @return void. + */ ++ (void)event:(NSString *)eventId; //等同于 event:eventId label:eventId; +/** 自定义事件,数量统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + */ ++ (void)event:(NSString *)eventId label:(NSString *)label; // label为nil或@""时,等同于 event:eventId label:eventId; + +/** 自定义事件,数量统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + */ ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes; + ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes counter:(int)number; + +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + beginEvent,endEvent要配对使用,也可以自己计时后通过durations参数传递进来 + + @param eventId 网站上注册的事件Id. + @param label 分类标签。不同的标签会分别进行统计,方便同一事件的不同标签的对比,为nil或空字符串时后台会生成和eventId同名的标签. + @param primarykey 这个参数用于和event_id一起标示一个唯一事件,并不会被统计;对于同一个事件在beginEvent和endEvent 中要传递相同的eventId 和 primarykey + @param millisecond 自己计时需要的话需要传毫秒进来 + @return void. + + @warning 每个event的attributes不能超过100个 + eventId、attributes中key和value都不能使用空格和特殊字符,必须是NSString,且长度不能超过255个字符(否则将截取前255个字符) + id, ts, du是保留字段,不能作为eventId及key的名称 +*/ ++ (void)beginEvent:(NSString *)eventId; + +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)beginEvent:(NSString *)eventId label:(NSString *)label; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId label:(NSString *)label; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)beginEvent:(NSString *)eventId primarykey :(NSString *)keyName attributes:(NSDictionary *)attributes; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId primarykey:(NSString *)keyName; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)event:(NSString *)eventId durations:(int)millisecond; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)event:(NSString *)eventId label:(NSString *)label durations:(int)millisecond; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes durations:(int)millisecond; + + +#pragma mark - user methods +/** active user sign-in. + 使用sign-In函数后,如果结束该PUID的统计,需要调用sign-Off函数 + @param puid : user's ID + @param provider : 不能以下划线"_"开头,使用大写字母和数字标识; 如果是上市公司,建议使用股票代码。 + @return void. + */ ++ (void)profileSignInWithPUID:(NSString *)puid; ++ (void)profileSignInWithPUID:(NSString *)puid provider:(NSString *)provider; + +/** active user sign-off. + 停止sign-in PUID的统计 + @return void. + */ ++ (void)profileSignOff; + +///--------------------------------------------------------------------------------------- +/// @name 地理位置设置 +/// 需要链接 CoreLocation.framework 并且 #import +///--------------------------------------------------------------------------------------- + +/** 设置经纬度信息 + @param latitude 纬度. + @param longitude 经度. + @return void + */ ++ (void)setLatitude:(double)latitude longitude:(double)longitude; + +/** 设置经纬度信息 + @param location CLLocation 经纬度信息 + @return void + */ ++ (void)setLocation:(CLLocation *)location; + +///--------------------------------------------------------------------------------------- +/// @name Utility函数 +///--------------------------------------------------------------------------------------- + +/** 判断设备是否越狱,依据是否存在apt和Cydia.app + */ ++ (BOOL)isJailbroken; + +/** 判断App是否被破解 + */ ++ (BOOL)isPirated; + +/** 设置 app secret + @param secret string + @return void. + */ ++ (void)setSecret:(NSString *)secret; + + +/** + * 设置预置事件属性 键值对 会覆盖同名的key + */ ++(void) registerPreProperties:(NSDictionary *)property; + +/** + * + * 删除指定预置事件属性 + @param key + */ ++(void) unregisterPreProperty:(NSString *)propertyName; + +/** + * 获取预置事件所有属性;如果不存在,则返回空。 + */ ++(NSDictionary *)getPreProperties; + +/** + *清空所有预置事件属性。 + */ ++(void)clearPreProperties; + + +/** + * 设置关注事件是否首次触发,只关注eventList前五个合法eventID.只要已经保存五个,此接口无效 + */ ++(void)setFirstLaunchEvent:(NSArray *)eventList; + +/** 设置是否自动采集页面, 默认NO(不自动采集). + @param value 设置为YES, umeng SDK 会将自动采集页面信息 + */ ++ (void)setAutoPageEnabled:(BOOL)value; + +/** + *集成测试。 + */ ++ (BOOL)handleUrl:(NSURL *)url; + + +@end + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/MobClick.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/MobClick.h.meta new file mode 100644 index 00000000..384b2500 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/MobClick.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 2916906b1c4114f81ac5c412f7421813 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMCommon.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMCommon.h new file mode 100644 index 00000000..3b6f087d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMCommon.h @@ -0,0 +1,19 @@ +// +// UMCommon.h +// UMCommon +// +// Created by San Zhang on 11/2/16. +// Copyright © 2016 UMeng. All rights reserved. +// + +#import + +//! Project version number for UMCommon. +FOUNDATION_EXPORT double UMCommonVersionNumber; + +//! Project version string for UMCommon. +FOUNDATION_EXPORT const unsigned char UMCommonVersionString[]; + +// In this header, you should import all the public headers of your framework using statements like #import + +#import diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMCommon.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMCommon.h.meta new file mode 100644 index 00000000..2e5b034c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMCommon.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 1d979109d45404e7b92a5f2df3b94323 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMConfigure.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMConfigure.h new file mode 100644 index 00000000..be799880 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMConfigure.h @@ -0,0 +1,45 @@ +// +// UMConfigure.h +// UMCommon +// +// Created by San Zhang on 9/6/16. +// Copyright © 2016 UMeng. All rights reserved. +// + +#import + +@interface UMConfigure : NSObject + +/** 初始化友盟所有组件产品 + @param appKey 开发者在友盟官网申请的appkey. + @param channel 渠道标识,可设置nil表示"App Store". + */ ++ (void)initWithAppkey:(NSString *)appKey channel:(NSString *)channel; + +/** 设置是否在console输出sdk的log信息. + @param bFlag 默认NO(不输出log); 设置为YES, 输出可供调试参考的log信息. 发布产品时必须设置为NO. + */ ++ (void)setLogEnabled:(BOOL)bFlag; + +/** 设置是否对日志信息进行加密, 默认NO(不加密). + @param value 设置为YES, umeng SDK 会将日志信息做加密处理 + */ ++ (void)setEncryptEnabled:(BOOL)value; + ++ (NSString *)umidString; + +/** + 集成测试需要device_id + */ ++ (NSString*)deviceIDForIntegration; + +/** 是否开启统计,默认为YES(开启状态) + @param value 设置为NO,可关闭友盟统计功能. + @return void. +*/ ++ (void)setAnalyticsEnabled:(BOOL)value; + +//获取zid ++ (NSString *)getUmengZID; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMConfigure.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMConfigure.h.meta new file mode 100644 index 00000000..faef912f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Headers/UMConfigure.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: aa945b5ed5db5491caa96823147a62ae +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/UMCommon b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/UMCommon new file mode 100644 index 00000000..ed3e49de Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/UMCommon differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/UMCommon.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/UMCommon.meta new file mode 100644 index 00000000..51720261 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/UMCommon.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 85dc8d09374f9442ab7c05b2b20caec7 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions.meta new file mode 100644 index 00000000..aebfe05d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6e54af84763bf4e1ca62ca08d7f916a7 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A.meta new file mode 100644 index 00000000..6a490e86 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 997580ef73024412793b42450baddb54 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers.meta new file mode 100644 index 00000000..a3e557d4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ecfde5bd4c94f4076a175d96428eac16 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/MobClick.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/MobClick.h new file mode 100644 index 00000000..34c39737 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/MobClick.h @@ -0,0 +1,226 @@ +// +// MobClick.h +// Analytics +// +// Copyright (C) 2010-2017 Umeng.com . All rights reserved. + +#import +#import + +@class CLLocation; +@interface MobClick : NSObject + +#pragma mark basics + +///--------------------------------------------------------------------------------------- +/// @name 设置 +///--------------------------------------------------------------------------------------- + + + +#pragma mark event logs +///--------------------------------------------------------------------------------------- +/// @name 页面计时 +///--------------------------------------------------------------------------------------- + +/** 手动页面时长统计, 记录某个页面展示的时长. + @param pageName 统计的页面名称. + @param seconds 单位为秒,int型. + @return void. + */ ++ (void)logPageView:(NSString *)pageName seconds:(int)seconds; + +/** 自动页面时长统计, 开始记录某个页面展示时长. + 使用方法:必须配对调用beginLogPageView:和endLogPageView:两个函数来完成自动统计,若只调用某一个函数不会生成有效数据。 + 在该页面展示时调用beginLogPageView:,当退出该页面时调用endLogPageView: + @param pageName 统计的页面名称. + @return void. + */ ++ (void)beginLogPageView:(NSString *)pageName; + +/** 自动页面时长统计, 结束记录某个页面展示时长. + 使用方法:必须配对调用beginLogPageView:和endLogPageView:两个函数来完成自动统计,若只调用某一个函数不会生成有效数据。 + 在该页面展示时调用beginLogPageView:,当退出该页面时调用endLogPageView: + @param pageName 统计的页面名称. + @return void. + */ ++ (void)endLogPageView:(NSString *)pageName; + + +///--------------------------------------------------------------------------------------- +/// @name 事件统计 +///--------------------------------------------------------------------------------------- + +/** 自定义事件,数量统计. +使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + + @param eventId 网站上注册的事件Id. + @param label 分类标签。不同的标签会分别进行统计,方便同一事件的不同标签的对比,为nil或空字符串时后台会生成和eventId同名的标签. + @param accumulation 累加值。为减少网络交互,可以自行对某一事件ID的某一分类标签进行累加,再传入次数作为参数。 + @return void. + */ ++ (void)event:(NSString *)eventId; //等同于 event:eventId label:eventId; +/** 自定义事件,数量统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + */ ++ (void)event:(NSString *)eventId label:(NSString *)label; // label为nil或@""时,等同于 event:eventId label:eventId; + +/** 自定义事件,数量统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + */ ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes; + ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes counter:(int)number; + +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + beginEvent,endEvent要配对使用,也可以自己计时后通过durations参数传递进来 + + @param eventId 网站上注册的事件Id. + @param label 分类标签。不同的标签会分别进行统计,方便同一事件的不同标签的对比,为nil或空字符串时后台会生成和eventId同名的标签. + @param primarykey 这个参数用于和event_id一起标示一个唯一事件,并不会被统计;对于同一个事件在beginEvent和endEvent 中要传递相同的eventId 和 primarykey + @param millisecond 自己计时需要的话需要传毫秒进来 + @return void. + + @warning 每个event的attributes不能超过100个 + eventId、attributes中key和value都不能使用空格和特殊字符,必须是NSString,且长度不能超过255个字符(否则将截取前255个字符) + id, ts, du是保留字段,不能作为eventId及key的名称 +*/ ++ (void)beginEvent:(NSString *)eventId; + +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)beginEvent:(NSString *)eventId label:(NSString *)label; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId label:(NSString *)label; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)beginEvent:(NSString *)eventId primarykey :(NSString *)keyName attributes:(NSDictionary *)attributes; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId primarykey:(NSString *)keyName; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)event:(NSString *)eventId durations:(int)millisecond; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)event:(NSString *)eventId label:(NSString *)label durations:(int)millisecond; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes durations:(int)millisecond; + + +#pragma mark - user methods +/** active user sign-in. + 使用sign-In函数后,如果结束该PUID的统计,需要调用sign-Off函数 + @param puid : user's ID + @param provider : 不能以下划线"_"开头,使用大写字母和数字标识; 如果是上市公司,建议使用股票代码。 + @return void. + */ ++ (void)profileSignInWithPUID:(NSString *)puid; ++ (void)profileSignInWithPUID:(NSString *)puid provider:(NSString *)provider; + +/** active user sign-off. + 停止sign-in PUID的统计 + @return void. + */ ++ (void)profileSignOff; + +///--------------------------------------------------------------------------------------- +/// @name 地理位置设置 +/// 需要链接 CoreLocation.framework 并且 #import +///--------------------------------------------------------------------------------------- + +/** 设置经纬度信息 + @param latitude 纬度. + @param longitude 经度. + @return void + */ ++ (void)setLatitude:(double)latitude longitude:(double)longitude; + +/** 设置经纬度信息 + @param location CLLocation 经纬度信息 + @return void + */ ++ (void)setLocation:(CLLocation *)location; + +///--------------------------------------------------------------------------------------- +/// @name Utility函数 +///--------------------------------------------------------------------------------------- + +/** 判断设备是否越狱,依据是否存在apt和Cydia.app + */ ++ (BOOL)isJailbroken; + +/** 判断App是否被破解 + */ ++ (BOOL)isPirated; + +/** 设置 app secret + @param secret string + @return void. + */ ++ (void)setSecret:(NSString *)secret; + + +/** + * 设置预置事件属性 键值对 会覆盖同名的key + */ ++(void) registerPreProperties:(NSDictionary *)property; + +/** + * + * 删除指定预置事件属性 + @param key + */ ++(void) unregisterPreProperty:(NSString *)propertyName; + +/** + * 获取预置事件所有属性;如果不存在,则返回空。 + */ ++(NSDictionary *)getPreProperties; + +/** + *清空所有预置事件属性。 + */ ++(void)clearPreProperties; + + +/** + * 设置关注事件是否首次触发,只关注eventList前五个合法eventID.只要已经保存五个,此接口无效 + */ ++(void)setFirstLaunchEvent:(NSArray *)eventList; + +/** 设置是否自动采集页面, 默认NO(不自动采集). + @param value 设置为YES, umeng SDK 会将自动采集页面信息 + */ ++ (void)setAutoPageEnabled:(BOOL)value; + +/** + *集成测试。 + */ ++ (BOOL)handleUrl:(NSURL *)url; + + +@end + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/MobClick.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/MobClick.h.meta new file mode 100644 index 00000000..14122cea --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/MobClick.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: a6e726a51694d476e92fdf23b931f861 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMCommon.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMCommon.h new file mode 100644 index 00000000..3b6f087d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMCommon.h @@ -0,0 +1,19 @@ +// +// UMCommon.h +// UMCommon +// +// Created by San Zhang on 11/2/16. +// Copyright © 2016 UMeng. All rights reserved. +// + +#import + +//! Project version number for UMCommon. +FOUNDATION_EXPORT double UMCommonVersionNumber; + +//! Project version string for UMCommon. +FOUNDATION_EXPORT const unsigned char UMCommonVersionString[]; + +// In this header, you should import all the public headers of your framework using statements like #import + +#import diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMCommon.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMCommon.h.meta new file mode 100644 index 00000000..42ef6785 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMCommon.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 97c69ad1460f842aaab4c9f086d392ac +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMConfigure.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMConfigure.h new file mode 100644 index 00000000..be799880 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMConfigure.h @@ -0,0 +1,45 @@ +// +// UMConfigure.h +// UMCommon +// +// Created by San Zhang on 9/6/16. +// Copyright © 2016 UMeng. All rights reserved. +// + +#import + +@interface UMConfigure : NSObject + +/** 初始化友盟所有组件产品 + @param appKey 开发者在友盟官网申请的appkey. + @param channel 渠道标识,可设置nil表示"App Store". + */ ++ (void)initWithAppkey:(NSString *)appKey channel:(NSString *)channel; + +/** 设置是否在console输出sdk的log信息. + @param bFlag 默认NO(不输出log); 设置为YES, 输出可供调试参考的log信息. 发布产品时必须设置为NO. + */ ++ (void)setLogEnabled:(BOOL)bFlag; + +/** 设置是否对日志信息进行加密, 默认NO(不加密). + @param value 设置为YES, umeng SDK 会将日志信息做加密处理 + */ ++ (void)setEncryptEnabled:(BOOL)value; + ++ (NSString *)umidString; + +/** + 集成测试需要device_id + */ ++ (NSString*)deviceIDForIntegration; + +/** 是否开启统计,默认为YES(开启状态) + @param value 设置为NO,可关闭友盟统计功能. + @return void. +*/ ++ (void)setAnalyticsEnabled:(BOOL)value; + +//获取zid ++ (NSString *)getUmengZID; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMConfigure.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMConfigure.h.meta new file mode 100644 index 00000000..686b91dd --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/Headers/UMConfigure.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 0dfb54bf156ea466182bf5aab47cd24c +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/UMCommon b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/UMCommon new file mode 100644 index 00000000..ed3e49de Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/UMCommon differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/UMCommon.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/UMCommon.meta new file mode 100644 index 00000000..949d62d1 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/A/UMCommon.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 4c6c898254c1c485f96c0d0cf59f42aa +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current.meta new file mode 100644 index 00000000..86daae03 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 81f15fbdd00a344cead32c6493609e79 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers.meta new file mode 100644 index 00000000..95bd155a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f007dcfd6148b4d58a2dea00829f66e3 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/MobClick.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/MobClick.h new file mode 100644 index 00000000..34c39737 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/MobClick.h @@ -0,0 +1,226 @@ +// +// MobClick.h +// Analytics +// +// Copyright (C) 2010-2017 Umeng.com . All rights reserved. + +#import +#import + +@class CLLocation; +@interface MobClick : NSObject + +#pragma mark basics + +///--------------------------------------------------------------------------------------- +/// @name 设置 +///--------------------------------------------------------------------------------------- + + + +#pragma mark event logs +///--------------------------------------------------------------------------------------- +/// @name 页面计时 +///--------------------------------------------------------------------------------------- + +/** 手动页面时长统计, 记录某个页面展示的时长. + @param pageName 统计的页面名称. + @param seconds 单位为秒,int型. + @return void. + */ ++ (void)logPageView:(NSString *)pageName seconds:(int)seconds; + +/** 自动页面时长统计, 开始记录某个页面展示时长. + 使用方法:必须配对调用beginLogPageView:和endLogPageView:两个函数来完成自动统计,若只调用某一个函数不会生成有效数据。 + 在该页面展示时调用beginLogPageView:,当退出该页面时调用endLogPageView: + @param pageName 统计的页面名称. + @return void. + */ ++ (void)beginLogPageView:(NSString *)pageName; + +/** 自动页面时长统计, 结束记录某个页面展示时长. + 使用方法:必须配对调用beginLogPageView:和endLogPageView:两个函数来完成自动统计,若只调用某一个函数不会生成有效数据。 + 在该页面展示时调用beginLogPageView:,当退出该页面时调用endLogPageView: + @param pageName 统计的页面名称. + @return void. + */ ++ (void)endLogPageView:(NSString *)pageName; + + +///--------------------------------------------------------------------------------------- +/// @name 事件统计 +///--------------------------------------------------------------------------------------- + +/** 自定义事件,数量统计. +使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + + @param eventId 网站上注册的事件Id. + @param label 分类标签。不同的标签会分别进行统计,方便同一事件的不同标签的对比,为nil或空字符串时后台会生成和eventId同名的标签. + @param accumulation 累加值。为减少网络交互,可以自行对某一事件ID的某一分类标签进行累加,再传入次数作为参数。 + @return void. + */ ++ (void)event:(NSString *)eventId; //等同于 event:eventId label:eventId; +/** 自定义事件,数量统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + */ ++ (void)event:(NSString *)eventId label:(NSString *)label; // label为nil或@""时,等同于 event:eventId label:eventId; + +/** 自定义事件,数量统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + */ ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes; + ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes counter:(int)number; + +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + beginEvent,endEvent要配对使用,也可以自己计时后通过durations参数传递进来 + + @param eventId 网站上注册的事件Id. + @param label 分类标签。不同的标签会分别进行统计,方便同一事件的不同标签的对比,为nil或空字符串时后台会生成和eventId同名的标签. + @param primarykey 这个参数用于和event_id一起标示一个唯一事件,并不会被统计;对于同一个事件在beginEvent和endEvent 中要传递相同的eventId 和 primarykey + @param millisecond 自己计时需要的话需要传毫秒进来 + @return void. + + @warning 每个event的attributes不能超过100个 + eventId、attributes中key和value都不能使用空格和特殊字符,必须是NSString,且长度不能超过255个字符(否则将截取前255个字符) + id, ts, du是保留字段,不能作为eventId及key的名称 +*/ ++ (void)beginEvent:(NSString *)eventId; + +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)beginEvent:(NSString *)eventId label:(NSString *)label; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId label:(NSString *)label; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)beginEvent:(NSString *)eventId primarykey :(NSString *)keyName attributes:(NSDictionary *)attributes; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)endEvent:(NSString *)eventId primarykey:(NSString *)keyName; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)event:(NSString *)eventId durations:(int)millisecond; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ + ++ (void)event:(NSString *)eventId label:(NSString *)label durations:(int)millisecond; +/** 自定义事件,时长统计. + 使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID. + */ ++ (void)event:(NSString *)eventId attributes:(NSDictionary *)attributes durations:(int)millisecond; + + +#pragma mark - user methods +/** active user sign-in. + 使用sign-In函数后,如果结束该PUID的统计,需要调用sign-Off函数 + @param puid : user's ID + @param provider : 不能以下划线"_"开头,使用大写字母和数字标识; 如果是上市公司,建议使用股票代码。 + @return void. + */ ++ (void)profileSignInWithPUID:(NSString *)puid; ++ (void)profileSignInWithPUID:(NSString *)puid provider:(NSString *)provider; + +/** active user sign-off. + 停止sign-in PUID的统计 + @return void. + */ ++ (void)profileSignOff; + +///--------------------------------------------------------------------------------------- +/// @name 地理位置设置 +/// 需要链接 CoreLocation.framework 并且 #import +///--------------------------------------------------------------------------------------- + +/** 设置经纬度信息 + @param latitude 纬度. + @param longitude 经度. + @return void + */ ++ (void)setLatitude:(double)latitude longitude:(double)longitude; + +/** 设置经纬度信息 + @param location CLLocation 经纬度信息 + @return void + */ ++ (void)setLocation:(CLLocation *)location; + +///--------------------------------------------------------------------------------------- +/// @name Utility函数 +///--------------------------------------------------------------------------------------- + +/** 判断设备是否越狱,依据是否存在apt和Cydia.app + */ ++ (BOOL)isJailbroken; + +/** 判断App是否被破解 + */ ++ (BOOL)isPirated; + +/** 设置 app secret + @param secret string + @return void. + */ ++ (void)setSecret:(NSString *)secret; + + +/** + * 设置预置事件属性 键值对 会覆盖同名的key + */ ++(void) registerPreProperties:(NSDictionary *)property; + +/** + * + * 删除指定预置事件属性 + @param key + */ ++(void) unregisterPreProperty:(NSString *)propertyName; + +/** + * 获取预置事件所有属性;如果不存在,则返回空。 + */ ++(NSDictionary *)getPreProperties; + +/** + *清空所有预置事件属性。 + */ ++(void)clearPreProperties; + + +/** + * 设置关注事件是否首次触发,只关注eventList前五个合法eventID.只要已经保存五个,此接口无效 + */ ++(void)setFirstLaunchEvent:(NSArray *)eventList; + +/** 设置是否自动采集页面, 默认NO(不自动采集). + @param value 设置为YES, umeng SDK 会将自动采集页面信息 + */ ++ (void)setAutoPageEnabled:(BOOL)value; + +/** + *集成测试。 + */ ++ (BOOL)handleUrl:(NSURL *)url; + + +@end + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/MobClick.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/MobClick.h.meta new file mode 100644 index 00000000..e28f3c7d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/MobClick.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 154c60bb3b97f4590be2ceb84c54aff0 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMCommon.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMCommon.h new file mode 100644 index 00000000..3b6f087d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMCommon.h @@ -0,0 +1,19 @@ +// +// UMCommon.h +// UMCommon +// +// Created by San Zhang on 11/2/16. +// Copyright © 2016 UMeng. All rights reserved. +// + +#import + +//! Project version number for UMCommon. +FOUNDATION_EXPORT double UMCommonVersionNumber; + +//! Project version string for UMCommon. +FOUNDATION_EXPORT const unsigned char UMCommonVersionString[]; + +// In this header, you should import all the public headers of your framework using statements like #import + +#import diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMCommon.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMCommon.h.meta new file mode 100644 index 00000000..499f2263 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMCommon.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: cd1caa40c21964cfb93226bf4b223c4e +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMConfigure.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMConfigure.h new file mode 100644 index 00000000..be799880 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMConfigure.h @@ -0,0 +1,45 @@ +// +// UMConfigure.h +// UMCommon +// +// Created by San Zhang on 9/6/16. +// Copyright © 2016 UMeng. All rights reserved. +// + +#import + +@interface UMConfigure : NSObject + +/** 初始化友盟所有组件产品 + @param appKey 开发者在友盟官网申请的appkey. + @param channel 渠道标识,可设置nil表示"App Store". + */ ++ (void)initWithAppkey:(NSString *)appKey channel:(NSString *)channel; + +/** 设置是否在console输出sdk的log信息. + @param bFlag 默认NO(不输出log); 设置为YES, 输出可供调试参考的log信息. 发布产品时必须设置为NO. + */ ++ (void)setLogEnabled:(BOOL)bFlag; + +/** 设置是否对日志信息进行加密, 默认NO(不加密). + @param value 设置为YES, umeng SDK 会将日志信息做加密处理 + */ ++ (void)setEncryptEnabled:(BOOL)value; + ++ (NSString *)umidString; + +/** + 集成测试需要device_id + */ ++ (NSString*)deviceIDForIntegration; + +/** 是否开启统计,默认为YES(开启状态) + @param value 设置为NO,可关闭友盟统计功能. + @return void. +*/ ++ (void)setAnalyticsEnabled:(BOOL)value; + +//获取zid ++ (NSString *)getUmengZID; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMConfigure.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMConfigure.h.meta new file mode 100644 index 00000000..1266431f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/Headers/UMConfigure.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 96d568fd4abdd43ddbe7b7f55ff66bf4 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/UMCommon b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/UMCommon new file mode 100644 index 00000000..ed3e49de Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/UMCommon differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/UMCommon.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/UMCommon.meta new file mode 100644 index 00000000..56aba1e6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMCommon.framework/Versions/Current/UMCommon.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 666b6754862c4426a9d6d64e5074348e +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework.meta new file mode 100644 index 00000000..4fee32f2 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 4278e4900f6174c0882241f49147c3c1 +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers.meta new file mode 100644 index 00000000..c6ed2c04 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1ab0da140c58e45feb3f261f5bc5efbd +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers/UMZid.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers/UMZid.h new file mode 100644 index 00000000..28331b01 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers/UMZid.h @@ -0,0 +1,26 @@ +// +// UMZid.h +// UMZid +// +// Created by UMZid on 8/29/20. +// Copyright © 2020 UMZid. All rights reserved. +// + +#import + +@interface UMZid : NSObject + +/// SDK初始化,异步请求uToken +/// @param appkey appkey +/// @param completion 请求uToken的回调,uToken为返回值,如果失败,uToken为空字符串@“” ++ (void)initWithAppKey:(NSString *)appkey completion:(void (^)(NSString *uToken))completion; + +/// 同步获得uToken,失败返回空字符串@“” ++ (NSString *)getZID; + +/// 获取SDK版本号 ++ (NSString *)getSDKVersion; + +/// 获得resetToken ++ (NSString *)getResetToken; +@end diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers/UMZid.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers/UMZid.h.meta new file mode 100644 index 00000000..d4c64fc1 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/Headers/UMZid.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 3d0cce2a83f804a82aea07401e1bb705 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/UMDevice b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/UMDevice new file mode 100644 index 00000000..1f0a156a Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/UMDevice differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/UMDevice.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/UMDevice.meta new file mode 100644 index 00000000..76703f6d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMDevice.framework/UMDevice.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 43dc7ebff4374441da8afbc95cb4d301 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework.meta new file mode 100644 index 00000000..e660a85f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: aefedffe2b3784048b9cb6f44e779a4d +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers.meta new file mode 100644 index 00000000..829b3206 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a11f8f24007f546f38b8ffd24139f9af +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfig.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfig.h new file mode 100644 index 00000000..5c9523ec --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfig.h @@ -0,0 +1,115 @@ +// +// UMRemoteConfig.h +// myFireBase +// +// Created by 张军华 on 2019/12/30. +// Copyright © 2019年 张军华. All rights reserved. +// + +#import +#import "UMRemoteConfigEnum.h" + +NS_ASSUME_NONNULL_BEGIN + +typedef void (^UMRemoteConfigFetchCompletion)(UMRemoteConfigFetchStatus status, + NSError *_Nullable error); + +typedef void (^UMRemoteConfigActivateCompletion)(NSError *_Nullable error); + +@protocol UMRemoteConfigDelegate + +@optional +/** + * @brief 获取服务器的网络请求的回调 + * @param status see UMRemoteConfigFetchStatus + * @param error 错误信息 + * @param userInfo 该回调的扩展信息 + * @note 调用函数触发此回调 + * fetchWithCompletionHandler + * fetchAndActivateWithCompletionHandler + */ +-(void)remoteConfigFetched:(UMRemoteConfigFetchStatus)status + error:(nullable NSError*)error + userInfo:(nullable id)userInfo; + + +/** + * @brief 远程配置被激活的回调 + * @param status see UMRemoteConfigActiveStatus + * @param error 错误信息 + * @param userInfo 该回调的扩展信息 + * @note 调用函数触发此回调 + * fetchAndActivateWithCompletionHandler + * activateWithCompletionHandler + */ +-(void)remoteConfigActivated:(UMRemoteConfigActiveStatus)status + error:(nullable NSError*)error + userInfo:(nullable id)userInfo; + + +/** + * @brief 配置已经准备就绪 + * @param status see UMRemoteConfigActiveStatus + * @param error 错误信息 + * @param userInfo 该回调的扩展信息 + * @note 调用函数触发此回调 + * fetchWithCompletionHandler + */ +-(void)remoteConfigReady:(UMRemoteConfigActiveStatus)status + error:(nullable NSError*)error + userInfo:(nullable id)userInfo; + +@end + +@class UMRemoteConfigSettings; +@interface UMRemoteConfig : NSObject + +@property(nonatomic,weak)id remoteConfigDelegate; +@property(nonatomic, readwrite, strong) UMRemoteConfigSettings *configSettings; + + +#pragma mark - init +/** + * @brief 远程配置单例 + * @param delegate see UMRemoteConfigDelegate + * @note 用户初始化时候, + 先调用 remoteConfigWithDelegate:(id)delegate,可以保证上次ready的数据可以回调给用户。 + */ ++ (UMRemoteConfig *)remoteConfigWithDelegate:(nullable id)delegate + withConfigSettings:(nullable UMRemoteConfigSettings*)configSettings; ++ (UMRemoteConfig *)remoteConfig; +#pragma mark - activate +/** + * @brief 激活本地配置 + * @param completionHandler 回调 + */ ++ (void)activateWithCompletionHandler:(nullable UMRemoteConfigActivateCompletion)completionHandler; + +#pragma mark - Get Config +/** + * @brief 获取配置信息 + * @param key 对应的key + * @note 获取配置的有限顺利,远程配置->Defaults + */ ++ (nullable id)configValueForKey:(nullable NSString *)key; + +#pragma mark - Defaults +/** + * @brief 设置本地默认配置 + * @param defaults 对应的本地配置 + */ ++ (void)setDefaults:(nullable NSDictionary *)defaults; + +/** + * @brief 设置本地默认配置 + * @param fileName 包含本地配置的plist文件 + */ ++ (void)setDefaultsFromPlistFileName:(nullable NSString *)fileName; + + ++(NSString*)sdkVersion; + + +@end + +NS_ASSUME_NONNULL_END diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfig.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfig.h.meta new file mode 100644 index 00000000..55d016af --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfig.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: e4a6bba60a00748fc8e4fd7692ff38f5 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigEnum.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigEnum.h new file mode 100644 index 00000000..cb895c3f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigEnum.h @@ -0,0 +1,54 @@ +// +// UMRemoteConfigEnum.h +// myFireBase +// +// Created by 张军华 on 2019/12/30. +// Copyright © 2019年 张军华. All rights reserved. +// + +#import + +NS_ASSUME_NONNULL_BEGIN + +/// Indicates whether updated data was successfully fetched. +typedef NS_ENUM(NSInteger, UMRemoteConfigFetchStatus) { + /// Config has never been fetched. + UMRemoteConfigFetchStatusNoFetchYet, + /// Config fetch succeeded. + UMRemoteConfigFetchStatusSuccess, + /// Config fetch failed. + UMRemoteConfigFetchStatusFailure, + /// Config fetch was throttled. + UMRemoteConfigFetchStatusThrottled, +}; + + +/// Indicates whether ActiveStatus in the local data . +typedef NS_ENUM(NSInteger, UMRemoteConfigActiveStatus) { + UMRemoteConfigActiveStatus_None, + UMRemoteConfigActiveStatus_Ready, + UMRemoteConfigActiveStatus_Active, + UMRemoteConfigActiveStatus_Expiration +}; + + + +///// Indicates whether updated data was successfully fetched and activated. +//typedef NS_ENUM(NSInteger, UMRemoteConfigFetchAndActivateStatus) { +// // The remote fetch succeeded and fetched data was activated. +// UMRemoteConfigFetchAndActivateStatusSuccessFetchedFromRemote, +// // The fetch and activate succeeded from already fetched but yet unexpired config data. You can +// // control this using minimumFetchInterval property in FIRRemoteConfigSettings. +// UMRemoteConfigFetchAndActivateStatusSuccessUsingPreFetchedData, +// // The fetch and activate failed. +// UMRemoteConfigFetchAndActivateStatusError +//}; + +//typedef NS_ENUM(NSInteger, UMRemoteConfigSource) { +// UMRemoteConfigSourceRemote, ///< The data source is the Remote Config service. +// UMRemoteConfigSourceDefault, ///< The data source is the DefaultConfig defined for this app. +// UMRemoteConfigSourceStatic, ///< The data doesn't exist, return a static initialized value. +//}; + + +NS_ASSUME_NONNULL_END diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigEnum.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigEnum.h.meta new file mode 100644 index 00000000..e130c14e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigEnum.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 3cf32a6b38f084f388aaebe3f59a7427 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigSettings.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigSettings.h new file mode 100644 index 00000000..be010ee0 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigSettings.h @@ -0,0 +1,31 @@ +// +// UMRemoteConfigSettings.h +// myFireBase +// +// Created by 张军华 on 2019/12/30. +// Copyright © 2019年 张军华. All rights reserved. +// + +#import + +NS_ASSUME_NONNULL_BEGIN + +@interface UMRemoteConfigSettings : NSObject + +/// Indicates the default value in seconds to set for the minimum interval that needs to elapse +/// before a fetch request can again be made to the Remote Config backend. After a fetch request to +/// the backend has succeeded, no additional fetch requests to the backend will be allowed until the +/// minimum fetch interval expires. +/// @note 目前没用,保留字段 +@property(atomic, assign) NSTimeInterval minimumFetchInterval; +/// Indicates the default value in seconds to abandon a pending fetch request made to the backend. +/// This value is set for outgoing requests as the timeoutIntervalForRequest as well as the +/// timeoutIntervalForResource on the NSURLSession's configuration. +/// @note 目前没用,保留字段 +@property(atomic, assign) NSTimeInterval fetchTimeout; +///active after fetch config +///获取远程配置后,是否激活 +@property(atomic, assign) BOOL activateAfterFetch; +@end + +NS_ASSUME_NONNULL_END diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigSettings.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigSettings.h.meta new file mode 100644 index 00000000..438ffaba --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Headers/UMRemoteConfigSettings.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 0556f6164631f4c92bc0223cec393374 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Info.plist b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Info.plist new file mode 100644 index 00000000..17567746 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Info.plist differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Info.plist.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Info.plist.meta new file mode 100644 index 00000000..87192fe5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: b361e0287429045fabadff2f64d973f6 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules.meta new file mode 100644 index 00000000..7d38d61f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f31ae5f02c7914e78a1f38b41b42cb2b +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules/module.modulemap b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules/module.modulemap new file mode 100644 index 00000000..c116aa09 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules/module.modulemap @@ -0,0 +1,6 @@ +framework module UMRemoteConfig { + umbrella header "UMRemoteConfig.h" + + export * + module * { export * } +} diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules/module.modulemap.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules/module.modulemap.meta new file mode 100644 index 00000000..14d51aa3 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/Modules/module.modulemap.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d9a427fb49c144255892fc0c4d8b3352 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/UMRemoteConfig b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/UMRemoteConfig new file mode 100644 index 00000000..cb0b33c3 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/UMRemoteConfig differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/UMRemoteConfig.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/UMRemoteConfig.meta new file mode 100644 index 00000000..f77d07e5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/UMRemoteConfig.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 8909b91d37c2a4dcd845a57d262c3526 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature.meta new file mode 100644 index 00000000..8daf4442 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3bd532d5215ec4eb9b02940deefda315 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeDirectory b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeDirectory new file mode 100644 index 00000000..f1eaaefa Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeDirectory differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeDirectory.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeDirectory.meta new file mode 100644 index 00000000..c29b151e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeDirectory.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: cb0dcc4a2228940969df6020d177aa41 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements new file mode 100644 index 00000000..25bf0886 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements-1 b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements-1 new file mode 100644 index 00000000..12c640c0 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements-1 differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements-1.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements-1.meta new file mode 100644 index 00000000..9b46c71a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements-1.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 23d65ff3516354187b8f7b387625274d +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements.meta new file mode 100644 index 00000000..2249ed21 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeRequirements.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 4b6c52098b47c4fb4b238ce9f89e818a +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeResources b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeResources new file mode 100644 index 00000000..38af5d9f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeResources @@ -0,0 +1,162 @@ + + + + + files + + Headers/UMRemoteConfig.h + + 2zOYD1TMew+VwIEBQFig4siBzYs= + + Headers/UMRemoteConfigEnum.h + + jIv4/Fu+lm5zYcJJbi3g8+9aZJ8= + + Headers/UMRemoteConfigSettings.h + + M0B9HHiPhuklGl2IFXOyP4SALJo= + + Info.plist + + qHjDD9JDk8koBxQ50RQa/BtOAU0= + + Modules/module.modulemap + + WzIWBeQkQ46cuqzMPGhKDhFgjJ4= + + + files2 + + Headers/UMRemoteConfig.h + + hash + + 2zOYD1TMew+VwIEBQFig4siBzYs= + + hash2 + + SXe+4paEy/wA38Wdk8dek0mmHwZNJrZNzcdYstVH2Ho= + + + Headers/UMRemoteConfigEnum.h + + hash + + jIv4/Fu+lm5zYcJJbi3g8+9aZJ8= + + hash2 + + CqjuRf2c5jVNo7Rh6RdTjgDMaCmvmY5WkNvagHLeM90= + + + Headers/UMRemoteConfigSettings.h + + hash + + M0B9HHiPhuklGl2IFXOyP4SALJo= + + hash2 + + 5D5D58088udYAz193uJHLPnoEHXxTrA4xmo3l1qveKI= + + + Modules/module.modulemap + + hash + + WzIWBeQkQ46cuqzMPGhKDhFgjJ4= + + hash2 + + MIYmrVaLytPwMR98BGJC/n+LLv141Li65jW0RdfTpSc= + + + + rules + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^version.plist$ + + + rules2 + + .*\.dSYM($|/) + + weight + 11 + + ^(.*/)?\.DS_Store$ + + omit + + weight + 2000 + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^Info\.plist$ + + omit + + weight + 20 + + ^PkgInfo$ + + omit + + weight + 20 + + ^embedded\.provisionprofile$ + + weight + 20 + + ^version\.plist$ + + weight + 20 + + + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeResources.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeResources.meta new file mode 100644 index 00000000..8ba3f171 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeResources.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 3ef438306f97a44aebc7094aa5976732 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeSignature b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeSignature new file mode 100644 index 00000000..227e2d16 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeSignature differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeSignature.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeSignature.meta new file mode 100644 index 00000000..a03bea7f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/UMRemoteConfig.framework/_CodeSignature/CodeSignature.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: e2d511065536445aa98e91d21fef1af6 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/iOS集成升级必读.pdf b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/iOS集成升级必读.pdf new file mode 100644 index 00000000..cdaab101 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/iOS集成升级必读.pdf differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/iOS集成升级必读.pdf.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/iOS集成升级必读.pdf.meta new file mode 100644 index 00000000..f4175dfd --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/common/common_ios_7.3.3/iOS集成升级必读.pdf.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 9e1856d530eda46bca1fee212e930769 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game.meta new file mode 100644 index 00000000..3bcc8a84 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4e0bc7137c7274a10949ed30e1465c24 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios.meta new file mode 100644 index 00000000..b655105a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: df91eb502022c44989be1368c5f65243 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework.meta new file mode 100644 index 00000000..add47e67 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 82243f7c540094876806c129b5e5ef09 +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers.meta new file mode 100644 index 00000000..562c29f6 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a031cd2ddf33f4df7b9fbcdd2694ec30 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers/MobClickGameAnalytics.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers/MobClickGameAnalytics.h new file mode 100755 index 00000000..818f8857 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers/MobClickGameAnalytics.h @@ -0,0 +1,173 @@ +// +// MobClickGameAnalytics.h +// Analytics +// +// Copyright (C) 2010-2014 Umeng.com . All rights reserved. +#import +#import + +@interface MobClickGameAnalytics : NSObject + +#pragma mark - account function +/** active user sign-in. + 使用sign-In函数后,如果结束该PUID的统计,需要调用sign-Off函数 + @param puid : user's ID + @param provider : 不能以下划线"_"开头,使用大写字母和数字标识; 如果是上市公司,建议使用股票代码。 + */ ++ (void)profileSignInWithPUID:(NSString *)puid provider:(NSString *)provider; ++ (void)profileSignInWithPUID:(NSString *)puid; + +/** active user sign-off. + 停止sign-in PUID的统计 + */ ++ (void)profileSignOff; + +#pragma mark GameLevel methods +///--------------------------------------------------------------------------------------- +/// @name set game level +///--------------------------------------------------------------------------------------- + +/** 设置玩家的等级. + */ + +/** 设置玩家等级属性. + @param level 玩家等级 + */ ++ (void)setUserLevelId:(int)level; + +///--------------------------------------------------------------------------------------- +/// @name 关卡统计 +///--------------------------------------------------------------------------------------- + +/** 记录玩家进入关卡,通过关卡及失败的情况. + */ + + +/** 进入关卡. + @param level 关卡 + */ ++ (void)startLevel:(NSString *)level; + +/** 通过关卡. + @param level 关卡,如果level == nil 则为当前关卡 + */ ++ (void)finishLevel:(NSString *)level; + +/** 未通过关卡. + @param level 关卡,如果level == nil 则为当前关卡 + */ + ++ (void)failLevel:(NSString *)level; + + +#pragma mark - +#pragma mark Pay methods + +///--------------------------------------------------------------------------------------- +/// @name 支付统计 +///--------------------------------------------------------------------------------------- + +/** 记录玩家交易兑换货币的情况 + @param currencyAmount 现金或等价物总额 + @param currencyType 为ISO4217定义的3位字母代码,如CNY,USD等(如使用其它自定义等价物作为现金,可使用ISO4217中未定义的3位字母组合传入货币类型) + @param virtualAmount 虚拟币数量 + @param channel 支付渠道 + @param orderId 交易订单ID + */ ++ (void)exchange:(NSString *)orderId currencyAmount:(double)currencyAmount currencyType:(NSString *)currencyType virtualCurrencyAmount:(double)virtualAmount paychannel:(int)channel; + +/** 玩家支付货币兑换虚拟币. + @param cash 真实货币数量 + @param source 支付渠道 + @param coin 虚拟币数量 + */ + ++ (void)pay:(double)cash source:(int)source coin:(double)coin; + +/** 玩家支付货币购买道具. + @param cash 真实货币数量 + @param source 支付渠道 + @param item 道具名称 + @param amount 道具数量 + @param price 道具单价 + */ ++ (void)pay:(double)cash source:(int)source item:(NSString *)item amount:(int)amount price:(double)price; + + +#pragma mark - +#pragma mark Buy methods + +///--------------------------------------------------------------------------------------- +/// @name 虚拟币购买统计 +///--------------------------------------------------------------------------------------- + +/** 记录玩家使用虚拟币的消费情况 + */ + + +/** 玩家使用虚拟币购买道具 +@param item 道具名称 +@param amount 道具数量 +@param price 道具单价 + */ ++ (void)buy:(NSString *)item amount:(int)amount price:(double)price; + + +#pragma mark - +#pragma mark Use methods + + +///--------------------------------------------------------------------------------------- +/// @name 道具消耗统计 +///--------------------------------------------------------------------------------------- + +/** 记录玩家道具消费情况 + */ + + +/** 玩家使用虚拟币购买道具 +@param item 道具名称 +@param amount 道具数量 +@param price 道具单价 + */ + ++ (void)use:(NSString *)item amount:(int)amount price:(double)price; + + +#pragma mark - +#pragma mark Bonus methods + + +///--------------------------------------------------------------------------------------- +/// @name 虚拟币及道具奖励统计 +///--------------------------------------------------------------------------------------- + +/** 记录玩家获赠虚拟币及道具的情况 + */ + + +/** 玩家获虚拟币奖励 +@param coin 虚拟币数量 +@param source 奖励方式 + */ + ++ (void)bonus:(double)coin source:(int)source; + +/** 玩家获道具奖励 +@param item 道具名称 +@param amount 道具数量 +@param price 道具单价 +@param source 奖励方式 + */ + ++ (void)bonus:(NSString *)item amount:(int)amount price:(double)price source:(int)source; + +#pragma mark DEPRECATED + +//已经被新的setUserLevelId:方法替代,请使用新的API。 ++ (void)setUserLevel:(NSString *)level; + +//已经被新的active user方法替代,请使用新的API。 ++ (void)setUserID:(NSString *)userId sex:(int)sex age:(int)age platform:(NSString *)platform; + +@end diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers/MobClickGameAnalytics.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers/MobClickGameAnalytics.h.meta new file mode 100644 index 00000000..45c7720a --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Headers/MobClickGameAnalytics.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 1cdff13d4c4444e588a7f02cde303d3b +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Info.plist b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Info.plist new file mode 100644 index 00000000..6095df2e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Info.plist @@ -0,0 +1,49 @@ + + + + + BuildMachineOSBuild + 17G65 + CFBundleDevelopmentRegion + en + CFBundleExecutable + UMAnalyticsGame + CFBundleIdentifier + com.umeng.testapp.UMAnalyticsGame + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + UMAnalyticsGame + CFBundleShortVersionString + 1.0.0 + CFBundleSupportedPlatforms + + iPhoneOS + + CFBundleVersion + 1 + DTCompiler + com.apple.compilers.llvm.clang.1_0 + DTPlatformBuild + 16B91 + DTPlatformName + iphoneos + DTPlatformVersion + 12.1 + DTSDKBuild + 16B91 + DTSDKName + iphoneos12.1 + DTXcode + 1010 + DTXcodeBuild + 10B61 + MinimumOSVersion + 8.0 + UIDeviceFamily + + 1 + 2 + + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Info.plist.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Info.plist.meta new file mode 100644 index 00000000..b015b388 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/Info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 7d80404b618044b118754649a2b145db +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/UMAnalyticsGame b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/UMAnalyticsGame new file mode 100644 index 00000000..be83279d Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/UMAnalyticsGame differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/UMAnalyticsGame.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/UMAnalyticsGame.meta new file mode 100644 index 00000000..59ee5651 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/game/game_ios/UMAnalyticsGame.framework/UMAnalyticsGame.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d82990410c2a34a1182e99c4770b5729 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties.meta new file mode 100644 index 00000000..6c6f1b75 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 732b6d264c86f40e9827e94714ef576d +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5.meta new file mode 100644 index 00000000..04a5f0df --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 126664485819a4dba9b1fd3f51412634 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework.meta new file mode 100644 index 00000000..12114208 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 4734f1cc020cf4d35926ffbc7b428ba1 +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/1.1.0_284361e9aad9bf95a33916c655ecefb720180108 b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/1.1.0_284361e9aad9bf95a33916c655ecefb720180108 new file mode 100644 index 00000000..e69de29b diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/1.1.0_284361e9aad9bf95a33916c655ecefb720180108.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/1.1.0_284361e9aad9bf95a33916c655ecefb720180108.meta new file mode 100644 index 00000000..5bde5df3 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/1.1.0_284361e9aad9bf95a33916c655ecefb720180108.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 78932ddd0383b4be08dba936b3204225 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers.meta new file mode 100644 index 00000000..d535d095 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 34d1bc915e95c4aefa3624fbaeea8182 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/AidProtocol.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/AidProtocol.h new file mode 100644 index 00000000..e431bf31 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/AidProtocol.h @@ -0,0 +1,23 @@ +// +// AidProtocol.h +// UtdidSDK +// +// Created by ALLEN on 14-12-22. +// Copyright (c) 2014年 Alvin. All rights reserved. +// + +#ifndef AidProtocol_h +#define AidProtocol_h + +#define EVENT_REQUEST_STARTED 1000 +#define EVENT_REQUEST_SUCCESS 1001 +#define EVENT_REQUEST_FAILED 1002 +#define EVENT_NETWORK_ERROR 1003 + +@protocol AidProtocolDelegate +@required +- (void) onAidEventChanged:(NSInteger)eventId + aid:(NSString *)aid; +@end + +#endif diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/AidProtocol.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/AidProtocol.h.meta new file mode 100644 index 00000000..cff3df87 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/AidProtocol.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: a60af4bbc0318497ab9589aff9f7ab61 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/UTDevice.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/UTDevice.h new file mode 100644 index 00000000..49ed9d19 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/UTDevice.h @@ -0,0 +1,56 @@ +// +// UTDevice.h +// +// +// Created by Alvin on 4/21/13. +// +// 设备信息的分装类:sdk合作开发需要用这个类提供的设备信息接口 + +// Version:utdid4all-1.1.0 + +#ifndef UTDIDDevice_h +#define UTDIDDevice_h + +#import "AidProtocol.h" + +@interface UTDevice : NSObject + +/** + * @brief 获取SDK生成的设备唯一标识. + * + * @warning 调用说明:这个设备唯一标识是持久的,并且格式安全,iOS6以及以下,多应用互通. + * + * 调用顺序:utdid任意时刻都可以调用. + * + * @return 24字节的设备唯一标识. + */ ++(NSString *) utdid; + +/** + * @brief 同步获得AID. + * + * @warning 调用说明:若本地端没有最新AID,将耗费远程通信时间并阻塞线程,建议将此调用置于非主线程,或使用{@link getAidAsync}异步获得AID。 + * + * 调用顺序:aid任意时刻都可以调用. + * + * @return AID. + */ ++(NSString *) aid:(NSString *)appName + token:(NSString *)token; + +/** + * @brief 异步请求AID. + * + * @warning 调用说明:若本地端没有最新AID,将建立异步请求获得AID, + * + * 调用顺序:aidAsync任意时刻都可以调用. + * + * @return AID. + */ ++(void) aidAsync:(NSString *)appName + token:(NSString *)token + aidDelegate:(id)aidDelegate; + +@end + +#endif diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/UTDevice.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/UTDevice.h.meta new file mode 100644 index 00000000..11aefa31 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Headers/UTDevice.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 7a12b57d7aaed4ac9b5f19c04a0ac3f1 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources.meta new file mode 100644 index 00000000..84ac8207 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3c06745cab7ac4ce39bd67aa7ff00b38 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources/Info.plist b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources/Info.plist new file mode 100644 index 00000000..cb425ba1 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources/Info.plist differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources/Info.plist.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources/Info.plist.meta new file mode 100644 index 00000000..9365b924 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Resources/Info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 69b4eb85b5fc344dc9025ba039d1ab02 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/UTDID b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/UTDID new file mode 100644 index 00000000..bc305754 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/UTDID differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/UTDID.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/UTDID.meta new file mode 100644 index 00000000..2a777dac --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/UTDID.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: ad975e7a0d8c14f9dad9348a1f3cd552 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions.meta new file mode 100644 index 00000000..9db126f9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e6430ba51eb9f4d56949e4b165d94041 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A.meta new file mode 100644 index 00000000..ffc394d9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0717463f5977a4523801f51f51247090 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers.meta new file mode 100644 index 00000000..3bbc68a4 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7d01e730983804348b0642336d2fcc59 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/AidProtocol.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/AidProtocol.h new file mode 100644 index 00000000..e431bf31 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/AidProtocol.h @@ -0,0 +1,23 @@ +// +// AidProtocol.h +// UtdidSDK +// +// Created by ALLEN on 14-12-22. +// Copyright (c) 2014年 Alvin. All rights reserved. +// + +#ifndef AidProtocol_h +#define AidProtocol_h + +#define EVENT_REQUEST_STARTED 1000 +#define EVENT_REQUEST_SUCCESS 1001 +#define EVENT_REQUEST_FAILED 1002 +#define EVENT_NETWORK_ERROR 1003 + +@protocol AidProtocolDelegate +@required +- (void) onAidEventChanged:(NSInteger)eventId + aid:(NSString *)aid; +@end + +#endif diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/AidProtocol.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/AidProtocol.h.meta new file mode 100644 index 00000000..f1d83f83 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/AidProtocol.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d39db42f49a844e249df222198936b63 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/UTDevice.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/UTDevice.h new file mode 100644 index 00000000..49ed9d19 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/UTDevice.h @@ -0,0 +1,56 @@ +// +// UTDevice.h +// +// +// Created by Alvin on 4/21/13. +// +// 设备信息的分装类:sdk合作开发需要用这个类提供的设备信息接口 + +// Version:utdid4all-1.1.0 + +#ifndef UTDIDDevice_h +#define UTDIDDevice_h + +#import "AidProtocol.h" + +@interface UTDevice : NSObject + +/** + * @brief 获取SDK生成的设备唯一标识. + * + * @warning 调用说明:这个设备唯一标识是持久的,并且格式安全,iOS6以及以下,多应用互通. + * + * 调用顺序:utdid任意时刻都可以调用. + * + * @return 24字节的设备唯一标识. + */ ++(NSString *) utdid; + +/** + * @brief 同步获得AID. + * + * @warning 调用说明:若本地端没有最新AID,将耗费远程通信时间并阻塞线程,建议将此调用置于非主线程,或使用{@link getAidAsync}异步获得AID。 + * + * 调用顺序:aid任意时刻都可以调用. + * + * @return AID. + */ ++(NSString *) aid:(NSString *)appName + token:(NSString *)token; + +/** + * @brief 异步请求AID. + * + * @warning 调用说明:若本地端没有最新AID,将建立异步请求获得AID, + * + * 调用顺序:aidAsync任意时刻都可以调用. + * + * @return AID. + */ ++(void) aidAsync:(NSString *)appName + token:(NSString *)token + aidDelegate:(id)aidDelegate; + +@end + +#endif diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/UTDevice.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/UTDevice.h.meta new file mode 100644 index 00000000..cdc1ee7f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Headers/UTDevice.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 26e946d0104ce42968de640f596db469 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources.meta new file mode 100644 index 00000000..bd78b79e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2a54659ce00054e7e8199001c5d27d96 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources/Info.plist b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources/Info.plist new file mode 100644 index 00000000..cb425ba1 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources/Info.plist differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources/Info.plist.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources/Info.plist.meta new file mode 100644 index 00000000..e26162cb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/Resources/Info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 3c2352d412b094517913f8daaf7a076c +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/UTDID b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/UTDID new file mode 100644 index 00000000..bc305754 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/UTDID differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/UTDID.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/UTDID.meta new file mode 100644 index 00000000..85c55b2c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/A/UTDID.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d54a8d5e026e145e492aeaf4abf7b0f7 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current.meta new file mode 100644 index 00000000..549799ff --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 16685698339f9444fb0658d257897705 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers.meta new file mode 100644 index 00000000..95b05b82 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ffd24466b88964be88bfd569eb43f602 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/AidProtocol.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/AidProtocol.h new file mode 100644 index 00000000..e431bf31 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/AidProtocol.h @@ -0,0 +1,23 @@ +// +// AidProtocol.h +// UtdidSDK +// +// Created by ALLEN on 14-12-22. +// Copyright (c) 2014年 Alvin. All rights reserved. +// + +#ifndef AidProtocol_h +#define AidProtocol_h + +#define EVENT_REQUEST_STARTED 1000 +#define EVENT_REQUEST_SUCCESS 1001 +#define EVENT_REQUEST_FAILED 1002 +#define EVENT_NETWORK_ERROR 1003 + +@protocol AidProtocolDelegate +@required +- (void) onAidEventChanged:(NSInteger)eventId + aid:(NSString *)aid; +@end + +#endif diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/AidProtocol.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/AidProtocol.h.meta new file mode 100644 index 00000000..cf83d87c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/AidProtocol.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: c0de8d6a8dbb54c17bf60801d05ff122 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/UTDevice.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/UTDevice.h new file mode 100644 index 00000000..49ed9d19 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/UTDevice.h @@ -0,0 +1,56 @@ +// +// UTDevice.h +// +// +// Created by Alvin on 4/21/13. +// +// 设备信息的分装类:sdk合作开发需要用这个类提供的设备信息接口 + +// Version:utdid4all-1.1.0 + +#ifndef UTDIDDevice_h +#define UTDIDDevice_h + +#import "AidProtocol.h" + +@interface UTDevice : NSObject + +/** + * @brief 获取SDK生成的设备唯一标识. + * + * @warning 调用说明:这个设备唯一标识是持久的,并且格式安全,iOS6以及以下,多应用互通. + * + * 调用顺序:utdid任意时刻都可以调用. + * + * @return 24字节的设备唯一标识. + */ ++(NSString *) utdid; + +/** + * @brief 同步获得AID. + * + * @warning 调用说明:若本地端没有最新AID,将耗费远程通信时间并阻塞线程,建议将此调用置于非主线程,或使用{@link getAidAsync}异步获得AID。 + * + * 调用顺序:aid任意时刻都可以调用. + * + * @return AID. + */ ++(NSString *) aid:(NSString *)appName + token:(NSString *)token; + +/** + * @brief 异步请求AID. + * + * @warning 调用说明:若本地端没有最新AID,将建立异步请求获得AID, + * + * 调用顺序:aidAsync任意时刻都可以调用. + * + * @return AID. + */ ++(void) aidAsync:(NSString *)appName + token:(NSString *)token + aidDelegate:(id)aidDelegate; + +@end + +#endif diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/UTDevice.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/UTDevice.h.meta new file mode 100644 index 00000000..c248070b --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Headers/UTDevice.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 9ec7950ef9d80433fb7e34f2e88faacb +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources.meta new file mode 100644 index 00000000..41160a63 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f818dd9985ec54db889afd2f6a2f8815 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources/Info.plist b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources/Info.plist new file mode 100644 index 00000000..cb425ba1 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources/Info.plist differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources/Info.plist.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources/Info.plist.meta new file mode 100644 index 00000000..110e5638 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/Resources/Info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 54b207d49acf24f5f9dd41cdedaf1354 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/UTDID b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/UTDID new file mode 100644 index 00000000..bc305754 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/UTDID differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/UTDID.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/UTDID.meta new file mode 100644 index 00000000..440bfbb9 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/thirdparties/thirdparties_ios_1.0.5/UTDID.framework/Versions/Current/UTDID.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 445dd21a2f6cd4bb49db7df06122e8a8 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog.meta new file mode 100644 index 00000000..9d9a68dc --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 41e3a47db720f434bb3df10457ca77ec +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0.meta new file mode 100644 index 00000000..b64e4353 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 41ff1104e6d554c26bb00b943002dfea +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle.meta new file mode 100644 index 00000000..140aecd0 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle.meta @@ -0,0 +1,81 @@ +fileFormatVersion: 2 +guid: 5c2336aa650a84fc8a4068b87051bc40 +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 0 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + iPhone: iOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj.meta new file mode 100644 index 00000000..55754316 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: aeac0d2fc6a1a4e3baf4907c86121882 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMAnalyticsGameLog.strings b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMAnalyticsGameLog.strings new file mode 100644 index 00000000..1a62b170 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMAnalyticsGameLog.strings @@ -0,0 +1,26 @@ +/* + UMCommonLog.strings + testUMCommonLog + + Created by 张军华 on 2017/12/11. + Copyright © 2017年 张军华. All rights reserved. +*/ + + + +//////////////////////////////////////////////// +//init begin + +analytics_init_error21 = "[AIE10014]MobClickGameAnalytics orderId 不能大于 1024字节 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error22 = "[AIE10014]MobClickGameAnalytics currencyType 不能大于 3字节 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; + + +analytics_init_error55 = "[AIE10014]MobClickGameAnalytics level不能为空 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error56 = "[AIE10014]MobClickGameAnalytics 请检查currencyAmount和virtualAmount是否正确 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error57 = "[AIE10014]请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; + + + + +analytics_init_warn8 = "setUserLevel 方法已下线,请使用setUserLevelId方法"; +analytics_init_warn9 = "setUserID 方法已下线,请使用其他相关User的方法"; diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMAnalyticsGameLog.strings.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMAnalyticsGameLog.strings.meta new file mode 100644 index 00000000..2acd31fa --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMAnalyticsGameLog.strings.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: ed5b941048c8544428731599e83f093d +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMCommonLog.strings b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMCommonLog.strings new file mode 100644 index 00000000..2ede7b39 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMCommonLog.strings @@ -0,0 +1,302 @@ +/* + UMCommonLog.strings + testUMCommonLog + + Created by 张军华 on 2017/12/11. + Copyright © 2017年 张军华. All rights reserved. +*/ + + + +//////////////////////////////////////////////// +//init begin +//init 20000 - 20250 +common_init_error1 = "[CIE10001]用户传入的appKey不合法,请到官网申请appkey,以免影响自己App的统计数据。网址如下:https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; + +common_init_warn1 = "当前传入的appkey和用户以前设置过的appkey不一样。"; +common_init_warn2 = "当前传入的channel渠道为空。"; +common_init_warn3 = "检测用户正在使用UI无埋点功能,检测到UMABTest.framework和UMAutoEventBinding.framework同时并存,在需要release发布需要删除UMABTest.framework。"; + +common_init_info1 = "正在使用国内Common组件化SDK版本。"; +common_init_info2 = "正在使用国际化Common组件化SDK版本。"; + +common_init_debug1 = "UMCommon版本号:%@。"; + +common_init_verbose1 = ""; + +//init end +//////////////////////////////////////////////// + +//////////////////////////////////////////////// +//integration_test begin +common_integrationtest_error1 = "experiment params invalid。"; +common_integrationtest_error2 = "unknow experiment group key。"; +common_integrationtest_error3 = "unknow experiment test key。"; +common_integrationtest_error4 = "experiment params invalid。"; + +//client_test end +//////////////////////////////////////////////// + + +//////////////////////////////////////////////// +//deviceToken begin +common_deviceToken_error1 = "error,tokenStringWithData, token inValid! [%ld]。"; + +//deviceToken end +//////////////////////////////////////////////// + + +//////////////////////////////////////////////// +//Envelope begin + +common_envelope_error1 = "信封json创建失败"; +common_envelope_error2 = "信封raw size:(%d)超过最大限制,创建失败"; +common_envelope_error3 = "信封压缩数据失败"; +common_envelope_error4 = "信封打包失败"; +common_envelope_error5 = "信封创建失败"; +common_envelope_error6 = "信封size:(%d)超过最大限制,创建失败"; +common_envelope_error7 = "发送信封(%@)失败"; +common_envelope_error8 = "网络请求失败(Response Applog) {\"fail\": \"error\"}"; +common_envelope_error9 = "网络请求失败(Response Applog) {\"fail\": \"statusCode\":%d}"; +common_envelope_error10 = "网络请求失败(Error Applog) %@"; + +common_envelope_warn1 = "信封数量超过最大限制%d,并且删除此文件名为:%@"; + +common_envelope_info1 = "准备发送信封"; +common_envelope_info2 = "信封名字的前缀:(%@)"; + +common_envelope_debug1 = "当前正在发送网络请求,还不能打包信封(network running=YES)。"; +common_envelope_debug2 = "当前网络状态不可用。"; +common_envelope_debug3 = "当前本地有信封存在,还不能打包新的信封。"; +common_envelope_debug4 = "生成信封(%@)成功"; +common_envelope_debug5 = "准备发送信封(%@)..."; +common_envelope_debug6 = "发送信封(%@)成功"; +common_envelope_debug7 = "网络请求成功(Response Applog) {\"success\": \"ok\"}"; +common_envelope_debug8 = "将要打包的有状态数据:%@"; +common_envelope_debug9 = "信封SerialNum:%d"; + +common_envelope_verbose1 = ""; + +//Envelope end +//////////////////////////////////////////////// + +//////////////////////////////////////////////// +//SLEnvelope begin + +common_slenvelope_error1 = "无状态信封json创建失败"; +common_slenvelope_error2 = "无状态信封raw size:(%d)超过最大限制,创建失败"; +common_slenvelope_error3 = "无状态信封压缩数据失败"; +common_slenvelope_error4 = "无状态信封打包失败"; +common_slenvelope_error5 = "无状态信封创建失败"; +common_slenvelope_error6 = "无状态信封size:(%d)超过最大限制,创建失败"; +common_slenvelope_error7 = "发送无状态信封(%@)失败"; +common_slenvelope_error8 = "无状态信封(%@)不存在"; +common_slenvelope_error9 = "网络请求失败(SLResponse Applog) {\"fail\": \"statusCode\":%d}"; + +common_slenvelope_warn1 = ""; + +common_slenvelope_info1 = ""; + + +common_slenvelope_debug1 = "生成无状态信封(%@)成功"; +common_slenvelope_debug2 = "准备发送无状态信封(%@)..."; +common_slenvelope_debug3 = "发送无状态信封(%@)成功"; +common_slenvelope_debug4 = "网络请求成功(SLResponse Applog) {\"success\": \"ok\"}"; +common_slenvelope_debug5 = "将要打包的无状态数据:%@"; + +common_slenvelope_verbose1 = ""; + + +//SLEnvelope end +//////////////////////////////////////////////// + +analytics_init_error1 = "[AIE10012]Latitude或者longitude设置错误 https://developer.umeng.com/docs/66632/detail/66999?um_channel=sdk"; +analytics_init_error2 = "[AIE10013]puid 为空 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error3 = "[AIE10013]puid 大于64字节 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error4 = "[AIE10013]provider 大于32字节 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error5 = "[AIE10005]请设置Dplus 场景 https://developer.umeng.com/docs/66632/detail/66990?um_channel=sdk"; +analytics_init_error6 = "数据库连接失败"; +analytics_init_error7 = "数据库已经打开"; +analytics_init_error8 = "修改表失败,TABLE %@ with columnName(%@)"; +analytics_init_error9 = "数据库运行失败,sql: %@, error: %s,errorCode:%d"; +analytics_init_error10 = "%@ 表创建失败"; +analytics_init_error11 = "%@ 表删除失败"; +analytics_init_error12 = "sql执行失败 %s"; +analytics_init_error13 = "%@ 表写入失败"; +analytics_init_error14 = "%@ 表修改失败"; +analytics_init_error15 = "[AIE10011]DeepLink url 不能大于 %d字节 https://developer.umeng.com/docs/66632/detail/66998?um_channel=sdk"; +analytics_init_error16 = "[AIE10011]DeepLink eventId %@ 不能大于 %d字节 https://developer.umeng.com/docs/66632/detail/66998?um_channel=sdk"; +analytics_init_error17 = "[AIE10006]%@是SDK保留字段,不能作为eventId使用 https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; +analytics_init_error18 = "[AIE1006]attributes中value 不能为 NSNull https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; +analytics_init_error19 = "[AIE10001]appkey 不能为空 https://developer.umeng.com/docs/66632/detail/66982?um_channel=sdk"; +analytics_init_error20 = "[AIE10005]MobClickGameAnalytics 是游戏API,请先设置游戏场景 https://developer.umeng.com/docs/66632/detail/66990?um_channel=sdk"; +analytics_init_error21 = "[AIE10014]MobClickGameAnalytics orderId 不能大于 1024字节 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error22 = "[AIE10014]MobClickGameAnalytics currencyType 不能大于 3字节 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error23 = "[AIE10005]DplusMobClick 是Dplus API,请先设置Dplus场景 https://developer.umeng.com/docs/66632/detail/66990?um_channel=sdk"; + +analytics_init_error24 = "[AIE1008]Dplus key:%@ 是预制字段,不能使用 https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; +analytics_init_error25 = "[AIE10008]Dplus property value只能使用NSString,NSNumber,NSArray类型 NSArray只能是(NSString,NSNumber)类型且不能为空 https://developer.umeng.com/docs/66993/detail/id?um_channel=sdk"; +analytics_init_error26 = "[AIE10008]Dplus property的key只能是NSString类型且不能为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; +analytics_init_error27 = "[AIE10008]Dplus property的value数组只能是NSString类型或NSNumber类型且不能为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; + +analytics_init_error30 = "[AIE10010]Dplus eventList必须是NSArray类型 https://developer.umeng.com/docs/66632/detail/66996?um_channel=sdk"; +analytics_init_error31 = "[AIE10010]Dplus eventList已存入5个,无法再添加 https://developer.umeng.com/docs/66632/detail/66996?um_channel=sdk"; +analytics_init_error32 = "[AIE10008]Dplus property只能是NSDictionary类型 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; +analytics_init_error33 = "[AIE10008]Dplus propertyName只能是NSString类型并且不能为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; + +analytics_init_error34 = "[AIE10006]关键字id, ts, du, dplus_st, %@是SDK保留字段,不能作为key使用。https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; +analytics_init_error35 = "[AIE10006]事件的key和value 必须是string类型,key不能大于%ld字节,value不能大于%ld字节 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error36 = "[AIE10008]Dplus eventName为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; +analytics_init_error37 = "[AIE10006]关键字id, ts, du, dplus_st是友盟SDK保留字段,不能作为key使用。https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; +analytics_init_error38 = "make envelope failed code:%d"; +analytics_init_error39 = "获取内容失败"; +analytics_init_error40 = "[AIE10006]eventId %@ 不能大于 %d字节 https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; +analytics_init_error41 = "[AIE10011]DeepLink 请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/66998?um_channel=sdk"; +analytics_init_error42 = "[AIE10010]Dplus eventList参数错误 https://developer.umeng.com/docs/66632/detail/66996?um_channel=sdk"; + +analytics_init_error43 = "[AIE10009]Dplus 请检查预置事件参数 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error44 = "[AIE10009]Dplus 预置事件的key和value 必须是string类型,key不能大于%d字节,value不能大于%d字节 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error45 = "[AIE10009]Dplus 预置事件property的value只能是NSString或者NSNumber类型且不能为空 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error46 = "[AIE10009]Dplus 预支事件property的key只能是NSString类型且不能为空 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error47 = "[AIE10009]Dplus 预置事件property只能是NSDictionary类型 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error48 = "[AIE10009]Dplus 预置事件property为空 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error49 = "[AIE10009]Dplus 请检查预置事件property中的key和value是否正确 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error50 = "[AIE10009]Dplus 预置事件propertyName只能是NSString类型并且不能为空 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; + +analytics_init_error51 = "[AIE10007]请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/66992?um_channel=sdk"; +analytics_init_error52 = "[AIE10007]pageName不能为空 https://developer.umeng.com/docs/66632/detail/66992?um_channel=sdk"; +analytics_init_error53 = "[AIE10008]Dplus property为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; + +analytics_init_error54 = "[AIE10006]请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; + +analytics_init_error55 = "[AIE10014]MobClickGameAnalytics level不能为空 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error56 = "[AIE10014]MobClickGameAnalytics 请检查currencyAmount和virtualAmount是否正确 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error57 = "[AIE10014]请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; + +analytics_init_error58 = "[AIE1008]超级属性设置失败 key:%@ 只能是%@、%@、%@、%@、%@字段,其他不能使用 https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; +analytics_init_error59 = "[AIE10006]自定义属性中事件的key %@ 必须是NSString类型,key不能大于%d字节 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error60 = "[AIE10006]自定义属性中事件的key value 不能为空 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error61 = "[AIE10006]自定义属性中事件的value %@ 只能是NSString,NSNumber,NSArray类型,value不能大于%d字节 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; + +analytics_init_error62 = "[AIE10006]自定义属性中事件的value 中的数组只能是NSString或NSNumber类型 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error63 = "[AIE10006]自定义属性中事件value中array的值不能大于%d字节 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error64 = "[AIE10006]自定义属性key:%@ 的value中的数组不能大于 %d 条 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error65 = "[AIE10006]自定义属性不能大于 %d 条 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; + +analytics_init_error66 = "[AIE1008]设置失败 key:%@ 不能大于%d字节 https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; + +analytics_init_error67 = "[AIE1008]设置失败 value:%@ 不能大于%d字节 https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; + +analytics_init_error68 = "预置事件条数大于 %d "; +analytics_init_error69 = "propertyName字节大于 %d "; + +analytics_init_error70 = "eventId:%@ 时长必须大于0小于 %d 毫秒 "; +analytics_init_error71 = "eventId不能为空 "; +analytics_init_error72 = "label %@ 不能大于 %d字节 "; +analytics_init_error73 = "label 必须是NSString类型 "; +analytics_init_error74 = "link 必须是NSUrl类型 "; +analytics_init_error75 = "link 不能为空 "; +analytics_init_error76 = "property的key只能是NSString类型且不能为空"; + + + + +analytics_init_warn1 = "provider 为空"; +analytics_init_warn3 = "错误信息表内容不是jsonString"; +analytics_init_warn5 = "请检查property中的key和value值"; +analytics_init_warn6 = "app已经启动"; +analytics_init_warn7 = "attributes中value 不能为空"; +analytics_init_warn8 = "setUserLevel 方法已下线,请使用setUserLevelId方法"; +analytics_init_warn9 = "setUserID 方法已下线,请使用其他相关User的方法"; + +analytics_init_warn10 = "[AIE10010]Dplus eventList为空 https://developer.umeng.com/docs/66632/detail/66996?um_channel=sdk"; + + +analytics_init_warn18 = "event label (%@) 不能大于%d字节"; +analytics_init_warn19 = "event事件在8小时内最多发送%d"; +analytics_init_warn20 = "track事件在8小时内最多发送%d"; +analytics_init_warn21 = "sessionId为空"; +analytics_init_warn22 = "不确定event 类型"; + +analytics_init_warn23 = "您已关闭使用统计功能"; + +analytics_init_warn24 = "key:%@ 超出限制字节,已被截取到%ld字节"; +analytics_init_warn25 = "value:%@ 超出限制字节,已被截取到%ld字节"; +analytics_init_warn26 = "预置事件条数大于 %ld ,已被截取只取前 %ld 条"; + +analytics_init_warn27 = "此方法不生效,如果使用请将setAutoPageEnabled方法设置为NO"; + +analytics_init_warn28 = "setAutoPageEnabled已调用过,此方法只能调用一次,建议在初始化之前使用"; + +analytics_init_warn29 = "建议不要在初始化之前使用事件,在初始化之前调用的事件有可能会丢失"; + + + + + + + +analytics_init_info1 = "超级属性注册成功"; +analytics_init_info2 = "缓存数据存储完成"; +analytics_init_info3 = "session 开始:%@"; +analytics_init_info4 = "session 结束:%@"; + +analytics_init_info9 = "dladdr(%p, ...) failed"; +analytics_init_info10 = "Invalid Mach-O header magic value: %x"; +analytics_init_info11 = "LC_SEGMENT 0x%08x"; +analytics_init_info12 = "数据过大,进行拆包"; +analytics_init_info13 = "数据过大,进行Dplus拆包"; +analytics_init_info14 = "数据过大,进行analytics拆包"; + +analytics_init_info15 = "已将是否自动获取页面设置为%@"; + + + + + + + + + + +analytics_init_debug1 = "UMAnalytics sdk版本号:%@,app 版本号:%@"; +analytics_init_debug2 = "UMAnalytics发送配置:sdk_version:%@, device_id:%@, model:%@, os_version:%@, app_version:%@"; +analytics_init_debug3 = "UMAnalytics统计发送内容:active_user:%@, activate_msg:%@, sessions:%@, ekv:%@"; +analytics_init_debug4 = "UMAnalytics游戏统计发送内容:gkv:%@"; +analytics_init_debug5 = "UMAnalytics Dplus发送内容:Dplus:%@"; +analytics_init_debug6 = "UMAnalytics error:%@"; +analytics_init_debug7 = "UMAnalytics event:%@"; +analytics_init_debug8 = "UMAnalytics session:%@"; +analytics_init_debug9 = "UMAnalytics ekv:%@"; +analytics_init_debug10 = "UMAnalytics gkv:%@"; +analytics_init_debug11 = "UMAnalytics app被杀死"; +analytics_init_debug12 = "UMAnalytics pageDuration:%@"; +analytics_init_debug13 = "UMAnalytics pageBegin=%@, beginTime:%@"; +analytics_init_debug14 = "UMAnalytics pageEnd=%@, duration:%lld"; +analytics_init_debug15 = "UMAnalytics eventBegin eventId=%@, label=%@"; +analytics_init_debug16 = "UMAnalytics ekvBegin ekvEvent.id=%@, ekvEvent.key=%@"; +analytics_init_debug17 = "UMAnalytics统计发送内容:active_user:%@, activate_msg:%@, sessions:%@, ekv:%@ ,error:%@"; + +analytics_init_debug18 = "UMAnalytics 写入缓存:%@,config:%@,row:%d"; +analytics_init_debug19 = "UMAnalytics 缓存读取:%@"; +analytics_init_debug20 = "UMAnalytics 缓存读取失败:config:%@,isReadyBuild:%d"; + + + + + + + + + + + + +analytics_init_verbose1 = "UMAnalytics 发送日志:%@"; +analytics_init_verbose2 = "UIApplicationWillTerminateNotification arrived"; +analytics_init_verbose3 = "app inactivate enter"; +analytics_init_verbose4 = "viewDidAppear is: %@"; +analytics_init_verbose5 = "viewDidDisappear is: %@"; + + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMCommonLog.strings.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMCommonLog.strings.meta new file mode 100644 index 00000000..fb06b20e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMCommonLog.strings.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: c2576ae34e41443c598d6210fc9d1495 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMPushLog.strings b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMPushLog.strings new file mode 100644 index 00000000..37dc38bb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMPushLog.strings @@ -0,0 +1,68 @@ +/* + UMPushLog.strings + UMessage + + Created by shile on 2017/12/11. + Copyright © 2017年 shile. All rights reserved. + */ + +//tag&alias +push_tagandalias_debug1 = "%@ 方法调用参数是: [%@]"; +push_tagandalias_debug2 = "%@ 方法调用成功, 返回的内容是:[%@], remainNumber [%ld]!"; +push_tagandalias_debug3 = "%@ 方法调用成功,name [%@] type [%@]!"; + +push_tagandalias_warning1 = "%@ 长度为0"; +push_tagandalias_warning2 = "%@ 长度超过了限制[%ld],长度是[%ld]"; +push_tagandalias_warning3 = "%@ 类型不为NSString或者为nil。"; + +push_tagandalias_error1 = "[PTAE10001] %@ 方法调用错误 ,token 为nil!,请查看:https://developer.umeng.com/docs/66632/detail/66964?um_channel=sdk"; +push_tagandalias_error2 = " %@ 方法调用错误 ,服务器异常或禁止请求,请检查是否调用错误!"; +push_tagandalias_error3 = "%@ 方法调用错误 ,error 是 %@,responseObject 内容是 %@!"; +push_tagandalias_error4 = "%@ 方法调用错误 ,请求过快,请检查是否调用正确!"; + +push_tagandalias_error6 = "%@ 失败,name [%@] type [%@]![%@]"; + + +//应用内消息 +push_innermessage_warning1 = "已经有相同的label存在,label为%@:"; + +push_innermessage_debug1 = "失败!error code:%d,sql:%@, result,SQL);"; + +push_innermessage_error1 = "应用内消息统计回传失败,responseObject[%@],error[%@]"; +push_innermessage_error2 = "获取UPush应用内 开屏 消息失败,请检查是否在后台创建消息,如不需要开屏功能,请移除相关代码!"; +push_innermessage_error3 = "获取UPush应用内 开屏 消息失败 [%@]!"; +push_innermessage_error4 = "获取UPush应用内 插屏 消息失败 [%@]!"; +push_innermessage_error5 = "label 格式错误,label只能为字符串,且不能为nil,或空串!"; +push_innermessage_error6 = "每个app只允许创建10个CardMessage!"; + + +//UMessage +push_umessage_info1 = "UMPush版本号:%@"; + +push_umessage_debug1 = "payload 内容是: [%@]"; +push_umessage_debug2 = "launchOptions 为 nil 或 class [%@] 不是 NSDictionary"; +push_umessage_debug3 = "消息到达!内容是:[%@]"; +push_umessage_debug4 = "这条消息已经上传到服务器了!msgid是:%@"; +push_umessage_debug5 = "UMPushMessage 内容是:[%@]"; +push_umessage_debug6 = "消息中不包含Alert, 内容是:[%@]"; +push_umessage_debug7 = "今天已经回传过 register 请求了"; +push_umessage_debug8 = "今天已经回传过 launch 请求了"; +push_umessage_debug9 = "responseDic 返回格式错误,内容是:[%@]"; +push_umessage_debug10 = "responseDic内容是:[%@]"; +push_umessage_debug11 = "clickPolicy 详情:[%d]"; +push_umessage_debug12 = "消息不属于友盟!"; +push_umessage_debug13 = "register devicetoken [%@]!"; +push_umessage_debug14 = "register AppKey [%@]!"; + +push_umessage_error1 = "userInfo 不包含msgid,或者消息不来自UPush!"; +push_umessage_error3 = "UMPushMessage init异常:[%@]"; +push_umessage_error4 = "application:didFailToRegisterForRemoteNotificationsWithError: [%@]"; +push_umessage_error5 = "token错误! [%ld]"; +push_umessage_error6 = "tagClass错误! tagClass是 [%@]"; +push_umessage_error7 = "错误! 每一最多只能发送[%ld]个tag,当前数量是[%ld]!"; +push_umessage_error8 = "WeightedTagClass错误! tagClass是 [%@]"; + + + + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMPushLog.strings.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMPushLog.strings.meta new file mode 100644 index 00000000..3fc2cfd8 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMPushLog.strings.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 1b7f73ea715474f248452839da3bf8ac +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMSocialPromptLocalizable.strings b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMSocialPromptLocalizable.strings new file mode 100644 index 00000000..5b74c8bc --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMSocialPromptLocalizable.strings @@ -0,0 +1,115 @@ + +// -------------- FAQ log + +//core模块的平台相关 +"core_platform_error_2" = "[SCE10001]创建平台失败:%@。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; +"core_platform_warn_1" = "[SCE10001]平台检查失败:%@,请检查是否实现 @selector(socialPlatformType),参考UMSocialPlatformConfig.h头文件说明。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; + +"core_share_error_7" = "[SCE10007]出现报错2014,请使用 HTTPS 图片 URL。 https://developer.umeng.com/docs/66632/detail/67029?um_channel=sdk"; +"core_info_1" = "[SCI10005]初始化平台参数中redirectURL参数的作用。 https://developer.umeng.com/docs/66632/detail/67027?um_channel=sdk"; +"core_info_2" = "[SCI10006]分享/授权登录后如果无法返回应用(微信、QQ、微博等平台)。 https://developer.umeng.com/docs/66632/detail/67028?um_channel=sdk"; +//core handle 协议相关 +"core_auth_error_1" = "[SCE10001]未发现第三方或自定义平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; +"core_auth_error_4" = "[SCE10001]未发现第三方或自定义平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; + +//core模块获得用户资料相关 +"core_getuserinfo_error_1" = "[SCE10001]未发现平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; + +//core模块分享相关 +"core_share_error_1" = "[SCE10008]传入平台('%@')的UMSocialMessageObject类型参数messageObject的数据类型无效,请检查\n1.messageObject是否空。\n2.messageObject.text和messageObject.shareObject是否同时为空。 https://developer.umeng.com/docs/66632/detail/67030?um_channel=sdk"; +"core_share_error_2" = "[SCE10001]未发现第三方或自定义平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; +"core_share_error_4" = "[SCE10001]未发现第三方或自定义平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; +"core_share_error_5" = "[SCE10001]未实现协议方法@selector(umSocial_ShareWithObject:withViewController:withCompletionHandler:):%@。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; + +// 分享面板 +"ui_info_1" = "[SUII10002]当前操作相关提示:分享面板无法弹出。 https://developer.umeng.com/docs/66632/detail/67033?um_channel=sdk"; +"ui_info_2" = "[SUII10003]分享面板图标不显示图片。 https://developer.umeng.com/docs/66632/detail/67034?um_channel=sdk"; + +"core_share_error_6" = "[SUIE10001]平台%@分享时,传入的参数currentViewController应该是nil或者是继承UIViewController的子类。 https://developer.umeng.com/docs/66632/detail/67032?um_channel=sdk"; +"core_auth_error_6" = "[SUIE10001]平台%@分享时,传入的参数currentViewController应该是nil或者是继承UIViewController的子类。 https://developer.umeng.com/docs/66632/detail/67032?um_channel=sdk"; +"core_getuserinfo_error_3" = "[SUIE10001]平台%@分享时,传入的参数currentViewController应该是nil或者是继承UIViewController的子类。 https://developer.umeng.com/docs/66632/detail/67032?um_channel=sdk"; + +//wechat +"wechat_auth_error_1" = "[SCE10002]请检查是否设置了微信的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; + +"wechat_share_error_1" = "[SCE10002]请检查是否设置了微信的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"wechat_share_error_2" = "[SCE10003]分享前,请检查微信是否安装。 https://developer.umeng.com/docs/66632/detail/67025?um_channel=sdk"; +"wechat_share_error_3" = "[SWE10001]当前的sdk不支持微信的OpenAPI,请更新最新的微信SDK。 https://developer.umeng.com/docs/66632/detail/67036?um_channel=sdk"; +"wechat_share_error_4" = "[SWE10002]微信分享不支持的分享类型,微信的分享类型为:文本,图片,网络链接,音乐链接,视频链接,Gif表情,文件。 https://developer.umeng.com/docs/66632/detail/67037?um_channel=sdk"; +"wechat_share_error_5" = "[SWE10003]下载UMShareImageObject的shareImage失败,请检查图片参数是否正确。(本地图片,请检查是否赋值,网络图片请检查是否为https,防止下载失败)。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; + +"wechat_shareWebPage_warn_1" = "[SWE10003]微信分享网页链接的时候,提供的缩略图为错误的下载url或者下载失败,具体的原因如下:%@。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; +"wechat_shareWebPage_warn_2" = "[SWE10003]微信分享网页链接的时候,提供的缩略图为错误的下载url或者下载失败。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; + +"wechat_shareImage_warn_1" = "[SWE10003]微信分享图片的时候,提供的缩略图为为错误的下载url或者下载失败,具体的原因如下:%@。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; +"wechat_shareImage_warn_2" = "[SWE10003]微信分享图片的时候,提供的缩略图为为错误的下载url或者下载失败。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; +// wechat info +"wechat_info_1" = "[SWI10004]分享面板中不显示微信。 https://developer.umeng.com/docs/66632/detail/67039?um_channel=sdk"; +"wechat_info_2" = "[SWI10005]如何获取微信code。 https://developer.umeng.com/docs/66632/detail/67040?um_channel=sdk"; +"wechat_info_3" = "[SWI10007]微信分享报错提示,请请检查微信是否安装。 https://developer.umeng.com/docs/66632/detail/67042?um_channel=sdk"; +"wechat_info_4" = "[SWI10008]微信授权登录提示该链接无法访问。 https://developer.umeng.com/docs/66632/detail/67043?um_channel=sdk"; +"wechat_info_5" = "[SWI10009]微信分享报错'由于invalid_app无法分享到微信。 https://developer.umeng.com/docs/66632/detail/67044?um_channel=sdk"; + +//qq +"qq_auth_error_1" = "[SCE10002]请检查是否设置了QQ的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"qq_auth_error_2" = "[SQE10001]授权失败,点击qq授权没有跳转,请查看是否设置了appid,查看初始化函数:[[UMSocialManager defaultManager] setPlaform:UMSocialPlatformType_QQ appKey:??? appSecret:nil redirectURL:???];。 https://developer.umeng.com/docs/66632/detail/67045?um_channel=sdk"; + +"qq_getuserinfo_error_1" = "[SCE10002]请检查是否设置了QQ的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"qq_getuserinfo_info_1" = "[SCE10004]可设置获得用户信息时是否清除缓存,通过UMSocialGlobal的isClearCacheWhenGetUserInfo变量来改变,默认是每次都清除用户的授权缓存。 https://developer.umeng.com/docs/66632/detail/67026?um_channel=sdk"; + + +"qq_share_error_1" = "[SCE10002]请检查是否设置了QQ的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"qq_share_error_2" = "[SCE10003]请检查是否安装了QQ。 https://developer.umeng.com/docs/66632/detail/67025?um_channel=sdk"; +"qq_share_error_3" = "[SQE10002]请检查当前的SDK是否支持API调用,如果不能请升级SDK或者QQ的版本。 https://developer.umeng.com/docs/66632/detail/67046?um_channel=sdk"; +"qq_share_error_4" = "[SQE10003]QQ分享不支持的分享类型,QQ的分享类型为:文本,图片,网络链接,音乐链接,视频链接。 https://developer.umeng.com/docs/66632/detail/67047?um_channel=sdk"; + +"qq_shareWebPage_warn_1" = "[SQE10004]QQ分享网页链接的时提供的缩略图为错误的下载url或者下载失败,具体的原因如下:%@。 https://developer.umeng.com/docs/66632/detail/67048?um_channel=sdk"; +"qq_shareWebPage_warn_2" = "[SQE10004]QQ分享网页链接的时提供的缩略图为错误的下载url或者下载失败。 https://developer.umeng.com/docs/66632/detail/67048?um_channel=sdk"; +//info +"qq_info_1" = "[SQI10005]QQ和TIM平台混淆问题。 https://developer.umeng.com/docs/66632/detail/67049?um_channel=sdk"; +"qq_info_2" = "[SQI10006]QQ登录时显示的应用名如何设置。 https://developer.umeng.com/docs/66632/detail/67050?um_channel=sdk"; +"qq_info_3" = "[SQI10007]QQ登录提示错误110406。 https://developer.umeng.com/docs/66632/detail/67051?um_channel=sdk"; +"qq_info_4" = "[SQI10008]QQ报错 100008 client request's app is not existed。 https://developer.umeng.com/docs/66632/detail/67053?um_channel=sdk"; + + +//sina +"sina_auth_error_1" = "[SCE10002]请检查是否设置了sina的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; + +"sina_getuserinfo_error_1" = "[SCE10002]请检查是否设置了sina的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; + +"sina_share_error_1" = "[SCE10002]请检查是否设置了sina的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"sina_share_error_2" = "[SSE10001]新浪分享不支持的分享类型,新浪的分享类型为:文本,图片,图文,网络链接,音乐链接,视频链接。 https://developer.umeng.com/docs/66632/detail/67329?um_channel=sdk"; +"sina_shareWebPage_error_1"="[SSE10002]新浪分享webpage类型(需要强制加入缩略图)错误,具体原因如下:%@。 https://developer.umeng.com/docs/66632/detail/67054?um_channel=sdk"; +"sina_shareText_Info_1" = "[SSI10003]新浪文本分享最大的字是140个,如果超过就不能分享成功,sdk默认开启截断功能,如果需要停止截断需要在调用分享前加入代码[UMSocialGlobal shareInstance].isTruncateShareText=NO。 https://developer.umeng.com/docs/66632/detail/67055?um_channel=sdk"; +//info +"sina_info_1" = "[SSI10004]微博分享 网页(WebPage)类型,链接在微博只显示为'网页链接'的文字。 https://developer.umeng.com/docs/66632/detail/67056?um_channel=sdk"; +"sina_info_2" = "[SSI10005]微博登录报错'sso package or sign error'。 https://developer.umeng.com/docs/66632/detail/67058?um_channel=sdk"; +"sina_info_3" = "[SSI10006]微博授权实现关注官方微博功能。 https://developer.umeng.com/docs/66632/detail/67059?um_channel=sdk"; +"sina_info_4" = "[SSI10007]微博报错 redirect url mismatch。 https://developer.umeng.com/docs/66632/detail/67060?um_channel=sdk"; + +// 钉钉支付宝 +// info +"ding_error_1" = "[SDE10001]支付宝/钉钉返回鉴权失败。 https://developer.umeng.com/docs/66632/detail/67062?um_channel=sdk"; + +//facebook +"facebook_share_error_1" = "[SFE10001]facebook分享不支持的分享类型,facebook的分享类型为:文本,图片,网络链接,音乐链接,视频链接。(新版的facebook采用的是对话框的形式分享的,如果设置文本的话需要有publish_actions权限调用OpenAPI)。 https://developer.umeng.com/docs/66632/detail/67064?um_channel=sdk"; +//error +"facebook_info_2" = "[SFI10002]FAQ: Facebook/Twitter分享点击分享后没有进入分享编辑页。 https://developer.umeng.com/docs/66632/detail/67065?um_channel=sdk"; +"facebook_info_3" = "[SFE10003]FAQ: Facebook分享失败,提示missing publish_actions permissions。 https://developer.umeng.com/docs/66632/detail/67066?um_channel=sdk"; + +//twitter +"twitter_auth_error_1" = "[SCE10002]请检查是否设置了 Twitter 的 URLScheme。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +//info +"twitter_info_1" = "[STI10001]Twitter如何获取TokenSecret。 https://developer.umeng.com/docs/66632/detail/67068?um_channel=sdk"; +"twitter_info_2" = "[STE10002]FAQ: Twitter 分享报错401。 https://developer.umeng.com/docs/66632/detail/67069?um_channel=sdk"; + +// --------- sdk 内 log +"core_version" = "UMShare版本号:%@。"; +// 实现handler协议提示 +"core_platform_warn_2" = "第三方或自定义平台异常:%@ > 未实现相应方法:@selector(umSocial_setAppKey:withAppSecret:withRedirectURL:)"; +"core_auth_error_2" = "未实现第三方或自定义协议方法@selector(umSocial_AuthorizeWithUserInfo:withViewController:withCompletionHandler:):%@"; +"core_auth_error_3" = "未实现第三方或自定义协议方法@selector(umSocial_cancelAuthWithCompletionHandler:):%@"; +"core_auth_error_5" = "未实现协议方法@selector(umSocial_AuthorizeWithUserInfo:withCompletionHandler:):%@"; +"core_getuserinfo_error_2" = "未实现第三方或自定义协议方法@selector(umSocial_RequestForUserProfileWithViewController:completion:):%@"; +"core_share_error_3" = "未实现第三方或自定义协议方法@selector(umSocial_ShareWithObject:withCompletionHandler:):%@"; + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMSocialPromptLocalizable.strings.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMSocialPromptLocalizable.strings.meta new file mode 100644 index 00000000..78fe0b6d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/en.lproj/UMSocialPromptLocalizable.strings.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: c8b1dc54ae71c4981afeee348a4b3190 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj.meta new file mode 100644 index 00000000..24c7bdde --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0616ab1c3b5de43a09f3d20944ad4ccc +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMAnalyticsGameLog.strings b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMAnalyticsGameLog.strings new file mode 100644 index 00000000..1a62b170 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMAnalyticsGameLog.strings @@ -0,0 +1,26 @@ +/* + UMCommonLog.strings + testUMCommonLog + + Created by 张军华 on 2017/12/11. + Copyright © 2017年 张军华. All rights reserved. +*/ + + + +//////////////////////////////////////////////// +//init begin + +analytics_init_error21 = "[AIE10014]MobClickGameAnalytics orderId 不能大于 1024字节 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error22 = "[AIE10014]MobClickGameAnalytics currencyType 不能大于 3字节 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; + + +analytics_init_error55 = "[AIE10014]MobClickGameAnalytics level不能为空 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error56 = "[AIE10014]MobClickGameAnalytics 请检查currencyAmount和virtualAmount是否正确 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error57 = "[AIE10014]请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; + + + + +analytics_init_warn8 = "setUserLevel 方法已下线,请使用setUserLevelId方法"; +analytics_init_warn9 = "setUserID 方法已下线,请使用其他相关User的方法"; diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMAnalyticsGameLog.strings.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMAnalyticsGameLog.strings.meta new file mode 100644 index 00000000..a71086ce --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMAnalyticsGameLog.strings.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 4a8e9f4d82ee14a72b6d01694d322c1f +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMCommonLog.strings b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMCommonLog.strings new file mode 100644 index 00000000..9c2889ef --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMCommonLog.strings @@ -0,0 +1,301 @@ +/* + UMCommonLog.strings + testUMCommonLog + + Created by 张军华 on 2017/12/11. + Copyright © 2017年 张军华. All rights reserved. + */ + + + +//////////////////////////////////////////////// +//init begin +//init 20000 - 20250 +common_init_error1 = "[CIE10001]用户传入的appKey不合法,请到官网申请appkey,以免影响自己App的统计数据。网址如下:https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; + +common_init_warn1 = "当前传入的appkey和用户以前设置过的appkey不一样。"; +common_init_warn2 = "当前传入的channel渠道为空。"; +common_init_warn3 = "检测用户正在使用UI无埋点功能,检测到UMABTest.framework和UMAutoEventBinding.framework同时并存,在需要release发布需要删除UMABTest.framework。"; + +common_init_info1 = "正在使用国内Common组件化SDK版本。"; +common_init_info2 = "正在使用国际化Common组件化SDK版本。"; + +common_init_debug1 = "UMCommon版本号:%@。"; + +common_init_verbose1 = ""; + +//init end +//////////////////////////////////////////////// + +//////////////////////////////////////////////// +//integration_test begin +common_integrationtest_error1 = "experiment params invalid。"; +common_integrationtest_error2 = "unknow experiment group key。"; +common_integrationtest_error3 = "unknow experiment test key。"; +common_integrationtest_error4 = "experiment params invalid。"; + +//client_test end +//////////////////////////////////////////////// + + +//////////////////////////////////////////////// +//deviceToken begin +common_deviceToken_error1 = "error,tokenStringWithData, token inValid! [%ld]。"; + +//deviceToken end +//////////////////////////////////////////////// + + +//////////////////////////////////////////////// +//Envelope begin + +common_envelope_error1 = "信封json创建失败"; +common_envelope_error2 = "信封raw size:(%d)超过最大限制,创建失败"; +common_envelope_error3 = "信封压缩数据失败"; +common_envelope_error4 = "信封打包失败"; +common_envelope_error5 = "信封创建失败"; +common_envelope_error6 = "信封size:(%d)超过最大限制,创建失败"; +common_envelope_error7 = "发送信封(%@)失败"; +common_envelope_error8 = "网络请求失败(Response Applog) {\"fail\": \"error\"}"; +common_envelope_error9 = "网络请求失败(Response Applog) {\"fail\": \"statusCode\":%d}"; +common_envelope_error10 = "网络请求失败(Error Applog) %@"; + +common_envelope_warn1 = "信封数量超过最大限制%d,并且删除此文件名为:%@"; + +common_envelope_info1 = "准备发送信封"; +common_envelope_info2 = "信封名字的前缀:(%@)"; + +common_envelope_debug1 = "当前正在发送网络请求,还不能打包信封(network running=YES)。"; +common_envelope_debug2 = "当前网络状态不可用。"; +common_envelope_debug3 = "当前本地有信封存在,还不能打包新的信封。"; +common_envelope_debug4 = "生成信封(%@)成功"; +common_envelope_debug5 = "准备发送信封(%@)..."; +common_envelope_debug6 = "发送信封(%@)成功"; +common_envelope_debug7 = "网络请求成功(Response Applog) {\"success\": \"ok\"}"; +common_envelope_debug8 = "将要打包的有状态数据:%@"; +common_envelope_debug9 = "信封SerialNum:%d"; + +common_envelope_verbose1 = ""; + +//Envelope end +//////////////////////////////////////////////// + +//////////////////////////////////////////////// +//SLEnvelope begin + +common_slenvelope_error1 = "无状态信封json创建失败"; +common_slenvelope_error2 = "无状态信封raw size:(%d)超过最大限制,创建失败"; +common_slenvelope_error3 = "无状态信封压缩数据失败"; +common_slenvelope_error4 = "无状态信封打包失败"; +common_slenvelope_error5 = "无状态信封创建失败"; +common_slenvelope_error6 = "无状态信封size:(%d)超过最大限制,创建失败"; +common_slenvelope_error7 = "发送无状态信封(%@)失败"; +common_slenvelope_error8 = "无状态信封(%@)不存在"; +common_slenvelope_error9 = "网络请求失败(SLResponse Applog) {\"fail\": \"statusCode\":%d}"; + +common_slenvelope_warn1 = ""; + +common_slenvelope_info1 = ""; + + +common_slenvelope_debug1 = "生成无状态信封(%@)成功"; +common_slenvelope_debug2 = "准备发送无状态信封(%@)..."; +common_slenvelope_debug3 = "发送无状态信封(%@)成功"; +common_slenvelope_debug4 = "网络请求成功(SLResponse Applog) {\"success\": \"ok\"}"; +common_slenvelope_debug5 = "将要打包的无状态数据:%@"; + +common_slenvelope_verbose1 = ""; + + +//SLEnvelope end +//////////////////////////////////////////////// + +analytics_init_error1 = "[AIE10012]Latitude或者longitude设置错误 https://developer.umeng.com/docs/66632/detail/66999?um_channel=sdk"; +analytics_init_error2 = "[AIE10013]puid 为空 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error3 = "[AIE10013]puid 大于64字节 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error4 = "[AIE10013]provider 大于32字节 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error5 = "[AIE10005]请设置Dplus 场景 https://developer.umeng.com/docs/66632/detail/66990?um_channel=sdk"; +analytics_init_error6 = "数据库连接失败"; +analytics_init_error7 = "数据库已经打开"; +analytics_init_error8 = "修改表失败,TABLE %@ with columnName(%@)"; +analytics_init_error9 = "数据库运行失败,sql: %@, error: %s,errorCode:%d"; +analytics_init_error10 = "%@ 表创建失败"; +analytics_init_error11 = "%@ 表删除失败"; +analytics_init_error12 = "sql执行失败 %s"; +analytics_init_error13 = "%@ 表写入失败"; +analytics_init_error14 = "%@ 表修改失败"; +analytics_init_error15 = "[AIE10011]DeepLink url 不能大于 %d字节 https://developer.umeng.com/docs/66632/detail/66998?um_channel=sdk"; +analytics_init_error16 = "[AIE10011]DeepLink eventId %@ 不能大于 %d字节 https://developer.umeng.com/docs/66632/detail/66998?um_channel=sdk"; +analytics_init_error17 = "[AIE10006]%@是SDK保留字段,不能作为eventId使用 https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; +analytics_init_error18 = "[AIE1006]attributes中value 不能为 NSNull https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; +analytics_init_error19 = "[AIE10001]appkey 不能为空 https://developer.umeng.com/docs/66632/detail/66982?um_channel=sdk"; +analytics_init_error20 = "[AIE10005]MobClickGameAnalytics 是游戏API,请先设置游戏场景 https://developer.umeng.com/docs/66632/detail/66990?um_channel=sdk"; +analytics_init_error21 = "[AIE10014]MobClickGameAnalytics orderId 不能大于 1024字节 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error22 = "[AIE10014]MobClickGameAnalytics currencyType 不能大于 3字节 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error23 = "[AIE10005]DplusMobClick 是Dplus API,请先设置Dplus场景 https://developer.umeng.com/docs/66632/detail/66990?um_channel=sdk"; + +analytics_init_error24 = "[AIE1008]Dplus key:%@ 是预制字段,不能使用 https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; +analytics_init_error25 = "[AIE10008]Dplus property value只能使用NSString,NSNumber,NSArray类型 NSArray只能是(NSString,NSNumber)类型且不能为空 https://developer.umeng.com/docs/66993/detail/id?um_channel=sdk"; +analytics_init_error26 = "[AIE10008]Dplus property的key只能是NSString类型且不能为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; +analytics_init_error27 = "[AIE10008]Dplus property的value数组只能是NSString类型或NSNumber类型且不能为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; + +analytics_init_error30 = "[AIE10010]Dplus eventList必须是NSArray类型 https://developer.umeng.com/docs/66632/detail/66996?um_channel=sdk"; +analytics_init_error31 = "[AIE10010]Dplus eventList已存入5个,无法再添加 https://developer.umeng.com/docs/66632/detail/66996?um_channel=sdk"; +analytics_init_error32 = "[AIE10008]Dplus property只能是NSDictionary类型 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; +analytics_init_error33 = "[AIE10008]Dplus propertyName只能是NSString类型并且不能为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; + +analytics_init_error34 = "[AIE10006]关键字id, ts, du, dplus_st, %@是SDK保留字段,不能作为key使用。https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; +analytics_init_error35 = "[AIE10006]事件的key和value 必须是string类型,key不能大于%ld字节,value不能大于%ld字节 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error36 = "[AIE10008]Dplus eventName为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; +analytics_init_error37 = "[AIE10006]关键字id, ts, du, dplus_st是友盟SDK保留字段,不能作为key使用。https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; +analytics_init_error38 = "make envelope failed code:%d"; +analytics_init_error39 = "获取内容失败"; +analytics_init_error40 = "[AIE10006]eventId %@ 不能大于 %d字节 https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; +analytics_init_error41 = "[AIE10011]DeepLink 请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/66998?um_channel=sdk"; +analytics_init_error42 = "[AIE10010]Dplus eventList参数错误 https://developer.umeng.com/docs/66632/detail/66996?um_channel=sdk"; + +analytics_init_error43 = "[AIE10009]Dplus 请检查预置事件参数 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error44 = "[AIE10009]Dplus 预置事件的key和value 必须是string类型,key不能大于%d字节,value不能大于%d字节 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error45 = "[AIE10009]Dplus 预置事件property的value只能是NSString或者NSNumber类型且不能为空 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error46 = "[AIE10009]Dplus 预支事件property的key只能是NSString类型且不能为空 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error47 = "[AIE10009]Dplus 预置事件property只能是NSDictionary类型 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error48 = "[AIE10009]Dplus 预置事件property为空 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error49 = "[AIE10009]Dplus 请检查预置事件property中的key和value是否正确 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; +analytics_init_error50 = "[AIE10009]Dplus 预置事件propertyName只能是NSString类型并且不能为空 https://developer.umeng.com/docs/66632/detail/66994?um_channel=sdk"; + +analytics_init_error51 = "[AIE10007]请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/66992?um_channel=sdk"; +analytics_init_error52 = "[AIE10007]pageName不能为空 https://developer.umeng.com/docs/66632/detail/66992?um_channel=sdk"; +analytics_init_error53 = "[AIE10008]Dplus property为空 https://developer.umeng.com/docs/66632/detail/66993?um_channel=sdk"; + +analytics_init_error54 = "[AIE10006]请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/66991?um_channel=sdk"; + +analytics_init_error55 = "[AIE10014]MobClickGameAnalytics level不能为空 https://developer.umeng.com/docs/66632/detail/67000?um_channel=sdk"; +analytics_init_error56 = "[AIE10014]MobClickGameAnalytics 请检查currencyAmount和virtualAmount是否正确 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; +analytics_init_error57 = "[AIE10014]请检查参数是否正确 https://developer.umeng.com/docs/66632/detail/67001?um_channel=sdk"; + +analytics_init_error58 = "[AIE1008]超级属性设置失败 key:%@ 只能是%@、%@、%@、%@、%@字段,其他不能使用 https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; +analytics_init_error59 = "[AIE10006]自定义属性中事件的key %@ 必须是NSString类型,key不能大于%d字节 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error60 = "[AIE10006]自定义属性中事件的key value 不能为空 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error61 = "[AIE10006]自定义属性中事件的value %@ 只能是NSString,NSNumber,NSArray类型,value不能大于%d字节 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; + +analytics_init_error62 = "[AIE10006]自定义属性中事件的value 中的数组只能是NSString或NSNumber类型 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error63 = "[AIE10006]自定义属性中事件value中array的值不能大于%d字节 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error64 = "[AIE10006]自定义属性key:%@ 的value中的数组不能大于 %d 条 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; +analytics_init_error65 = "[AIE10006]自定义属性不能大于 %d 条 https://developer.umeng.com/docs/66991/detail/id?um_channel=sdk"; + +analytics_init_error66 = "[AIE1008]设置失败 key:%@ 不能大于%d字节 https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; + +analytics_init_error67 = "[AIE1008]设置失败 value:%@ 不能大于%d字节 https://developer.umeng.com/docs/66632/detail/67191?um_channel=sdk"; + +analytics_init_error68 = "预置事件条数大于 %d "; +analytics_init_error69 = "propertyName字节大于 %d "; + +analytics_init_error70 = "eventId:%@ 时长必须大于0小于 %d 毫秒 "; +analytics_init_error71 = "eventId不能为空 "; +analytics_init_error72 = "label %@ 不能大于 %d字节 "; +analytics_init_error73 = "label 必须是NSString类型 "; +analytics_init_error74 = "link 必须是NSUrl类型 "; +analytics_init_error75 = "link 不能为空 "; +analytics_init_error76 = "property的key只能是NSString类型且不能为空"; + + + + +analytics_init_warn1 = "provider 为空"; +analytics_init_warn3 = "错误信息表内容不是jsonString"; +analytics_init_warn5 = "请检查property中的key和value值"; +analytics_init_warn6 = "app已经启动"; +analytics_init_warn7 = "attributes中value 不能为空"; +analytics_init_warn8 = "setUserLevel 方法已下线,请使用setUserLevelId方法"; +analytics_init_warn9 = "setUserID 方法已下线,请使用其他相关User的方法"; + +analytics_init_warn10 = "[AIE10010]Dplus eventList为空 https://developer.umeng.com/docs/66632/detail/66996?um_channel=sdk"; + + +analytics_init_warn18 = "event label (%@) 不能大于%d字节"; +analytics_init_warn19 = "event事件在8小时内最多发送%d"; +analytics_init_warn20 = "track事件在8小时内最多发送%d"; +analytics_init_warn21 = "sessionId为空"; +analytics_init_warn22 = "不确定event 类型"; + +analytics_init_warn23 = "您已关闭使用统计功能"; + +analytics_init_warn24 = "key:%@ 超出限制字节,已被截取到%ld字节"; +analytics_init_warn25 = "value:%@ 超出限制字节,已被截取到%ld字节"; +analytics_init_warn26 = "预置事件条数大于 %ld ,已被截取只取前 %ld 条"; + +analytics_init_warn27 = "此方法不生效,如果使用请将setAutoPageEnabled方法设置为NO"; + +analytics_init_warn28 = "setAutoPageEnabled已调用过,此方法只能调用一次,建议在初始化之前使用"; + +analytics_init_warn29 = "建议不要在初始化之前使用事件,在初始化之前调用的事件有可能会丢失"; + + + + + + + +analytics_init_info1 = "超级属性注册成功"; +analytics_init_info2 = "缓存数据存储完成"; +analytics_init_info3 = "session 开始:%@"; +analytics_init_info4 = "session 结束:%@"; + +analytics_init_info9 = "dladdr(%p, ...) failed"; +analytics_init_info10 = "Invalid Mach-O header magic value: %x"; +analytics_init_info11 = "LC_SEGMENT 0x%08x"; +analytics_init_info12 = "数据过大,进行拆包"; +analytics_init_info13 = "数据过大,进行Dplus拆包"; +analytics_init_info14 = "数据过大,进行analytics拆包"; + +analytics_init_info15 = "已将是否自动获取页面设置为%@"; + + + + + + + + + + +analytics_init_debug1 = "UMAnalytics sdk版本号:%@,app 版本号:%@"; +analytics_init_debug2 = "UMAnalytics发送配置:sdk_version:%@, device_id:%@, model:%@, os_version:%@, app_version:%@"; +analytics_init_debug3 = "UMAnalytics统计发送内容:active_user:%@, activate_msg:%@, sessions:%@, ekv:%@"; +analytics_init_debug4 = "UMAnalytics游戏统计发送内容:gkv:%@"; +analytics_init_debug5 = "UMAnalytics Dplus发送内容:Dplus:%@"; +analytics_init_debug6 = "UMAnalytics error:%@"; +analytics_init_debug7 = "UMAnalytics event:%@"; +analytics_init_debug8 = "UMAnalytics session:%@"; +analytics_init_debug9 = "UMAnalytics ekv:%@"; +analytics_init_debug10 = "UMAnalytics gkv:%@"; +analytics_init_debug11 = "UMAnalytics app被杀死"; +analytics_init_debug12 = "UMAnalytics pageDuration:%@"; +analytics_init_debug13 = "UMAnalytics pageBegin=%@, beginTime:%@"; +analytics_init_debug14 = "UMAnalytics pageEnd=%@, duration:%lld"; +analytics_init_debug15 = "UMAnalytics eventBegin eventId=%@, label=%@"; +analytics_init_debug16 = "UMAnalytics ekvBegin ekvEvent.id=%@, ekvEvent.key=%@"; +analytics_init_debug17 = "UMAnalytics统计发送内容:active_user:%@, activate_msg:%@, sessions:%@, ekv:%@ ,error:%@"; + +analytics_init_debug18 = "UMAnalytics 写入缓存:%@,config:%@,row:%d"; +analytics_init_debug19 = "UMAnalytics 缓存读取:%@"; +analytics_init_debug20 = "UMAnalytics 缓存读取失败:config:%@,isReadyBuild:%d"; + + + + + + + + + + + +analytics_init_verbose1 = "UMAnalytics 发送日志:%@"; +analytics_init_verbose2 = "UIApplicationWillTerminateNotification arrived"; +analytics_init_verbose3 = "app inactivate enter"; +analytics_init_verbose4 = "viewDidAppear is: %@"; +analytics_init_verbose5 = "viewDidDisappear is: %@"; + + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMCommonLog.strings.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMCommonLog.strings.meta new file mode 100644 index 00000000..d4c296ea --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMCommonLog.strings.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d96c960245f9047beb61754859106465 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMPushLog.strings b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMPushLog.strings new file mode 100644 index 00000000..37dc38bb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMPushLog.strings @@ -0,0 +1,68 @@ +/* + UMPushLog.strings + UMessage + + Created by shile on 2017/12/11. + Copyright © 2017年 shile. All rights reserved. + */ + +//tag&alias +push_tagandalias_debug1 = "%@ 方法调用参数是: [%@]"; +push_tagandalias_debug2 = "%@ 方法调用成功, 返回的内容是:[%@], remainNumber [%ld]!"; +push_tagandalias_debug3 = "%@ 方法调用成功,name [%@] type [%@]!"; + +push_tagandalias_warning1 = "%@ 长度为0"; +push_tagandalias_warning2 = "%@ 长度超过了限制[%ld],长度是[%ld]"; +push_tagandalias_warning3 = "%@ 类型不为NSString或者为nil。"; + +push_tagandalias_error1 = "[PTAE10001] %@ 方法调用错误 ,token 为nil!,请查看:https://developer.umeng.com/docs/66632/detail/66964?um_channel=sdk"; +push_tagandalias_error2 = " %@ 方法调用错误 ,服务器异常或禁止请求,请检查是否调用错误!"; +push_tagandalias_error3 = "%@ 方法调用错误 ,error 是 %@,responseObject 内容是 %@!"; +push_tagandalias_error4 = "%@ 方法调用错误 ,请求过快,请检查是否调用正确!"; + +push_tagandalias_error6 = "%@ 失败,name [%@] type [%@]![%@]"; + + +//应用内消息 +push_innermessage_warning1 = "已经有相同的label存在,label为%@:"; + +push_innermessage_debug1 = "失败!error code:%d,sql:%@, result,SQL);"; + +push_innermessage_error1 = "应用内消息统计回传失败,responseObject[%@],error[%@]"; +push_innermessage_error2 = "获取UPush应用内 开屏 消息失败,请检查是否在后台创建消息,如不需要开屏功能,请移除相关代码!"; +push_innermessage_error3 = "获取UPush应用内 开屏 消息失败 [%@]!"; +push_innermessage_error4 = "获取UPush应用内 插屏 消息失败 [%@]!"; +push_innermessage_error5 = "label 格式错误,label只能为字符串,且不能为nil,或空串!"; +push_innermessage_error6 = "每个app只允许创建10个CardMessage!"; + + +//UMessage +push_umessage_info1 = "UMPush版本号:%@"; + +push_umessage_debug1 = "payload 内容是: [%@]"; +push_umessage_debug2 = "launchOptions 为 nil 或 class [%@] 不是 NSDictionary"; +push_umessage_debug3 = "消息到达!内容是:[%@]"; +push_umessage_debug4 = "这条消息已经上传到服务器了!msgid是:%@"; +push_umessage_debug5 = "UMPushMessage 内容是:[%@]"; +push_umessage_debug6 = "消息中不包含Alert, 内容是:[%@]"; +push_umessage_debug7 = "今天已经回传过 register 请求了"; +push_umessage_debug8 = "今天已经回传过 launch 请求了"; +push_umessage_debug9 = "responseDic 返回格式错误,内容是:[%@]"; +push_umessage_debug10 = "responseDic内容是:[%@]"; +push_umessage_debug11 = "clickPolicy 详情:[%d]"; +push_umessage_debug12 = "消息不属于友盟!"; +push_umessage_debug13 = "register devicetoken [%@]!"; +push_umessage_debug14 = "register AppKey [%@]!"; + +push_umessage_error1 = "userInfo 不包含msgid,或者消息不来自UPush!"; +push_umessage_error3 = "UMPushMessage init异常:[%@]"; +push_umessage_error4 = "application:didFailToRegisterForRemoteNotificationsWithError: [%@]"; +push_umessage_error5 = "token错误! [%ld]"; +push_umessage_error6 = "tagClass错误! tagClass是 [%@]"; +push_umessage_error7 = "错误! 每一最多只能发送[%ld]个tag,当前数量是[%ld]!"; +push_umessage_error8 = "WeightedTagClass错误! tagClass是 [%@]"; + + + + + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMPushLog.strings.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMPushLog.strings.meta new file mode 100644 index 00000000..85c5fd27 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMPushLog.strings.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 8a952bfc589844a8e91d3810176b0a47 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMSocialPromptLocalizable.strings b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMSocialPromptLocalizable.strings new file mode 100644 index 00000000..5b74c8bc --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMSocialPromptLocalizable.strings @@ -0,0 +1,115 @@ + +// -------------- FAQ log + +//core模块的平台相关 +"core_platform_error_2" = "[SCE10001]创建平台失败:%@。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; +"core_platform_warn_1" = "[SCE10001]平台检查失败:%@,请检查是否实现 @selector(socialPlatformType),参考UMSocialPlatformConfig.h头文件说明。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; + +"core_share_error_7" = "[SCE10007]出现报错2014,请使用 HTTPS 图片 URL。 https://developer.umeng.com/docs/66632/detail/67029?um_channel=sdk"; +"core_info_1" = "[SCI10005]初始化平台参数中redirectURL参数的作用。 https://developer.umeng.com/docs/66632/detail/67027?um_channel=sdk"; +"core_info_2" = "[SCI10006]分享/授权登录后如果无法返回应用(微信、QQ、微博等平台)。 https://developer.umeng.com/docs/66632/detail/67028?um_channel=sdk"; +//core handle 协议相关 +"core_auth_error_1" = "[SCE10001]未发现第三方或自定义平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; +"core_auth_error_4" = "[SCE10001]未发现第三方或自定义平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; + +//core模块获得用户资料相关 +"core_getuserinfo_error_1" = "[SCE10001]未发现平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; + +//core模块分享相关 +"core_share_error_1" = "[SCE10008]传入平台('%@')的UMSocialMessageObject类型参数messageObject的数据类型无效,请检查\n1.messageObject是否空。\n2.messageObject.text和messageObject.shareObject是否同时为空。 https://developer.umeng.com/docs/66632/detail/67030?um_channel=sdk"; +"core_share_error_2" = "[SCE10001]未发现第三方或自定义平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; +"core_share_error_4" = "[SCE10001]未发现第三方或自定义平台相应类:%@\n请检查:\n1、平台类已实现协议\n2、此平台枚举值在正常枚举区间内,参考UMSocialPlatformConfig.h —> UMSocialPlatformType枚举。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; +"core_share_error_5" = "[SCE10001]未实现协议方法@selector(umSocial_ShareWithObject:withViewController:withCompletionHandler:):%@。 https://developer.umeng.com/docs/66632/detail/67023?um_channel=sdk"; + +// 分享面板 +"ui_info_1" = "[SUII10002]当前操作相关提示:分享面板无法弹出。 https://developer.umeng.com/docs/66632/detail/67033?um_channel=sdk"; +"ui_info_2" = "[SUII10003]分享面板图标不显示图片。 https://developer.umeng.com/docs/66632/detail/67034?um_channel=sdk"; + +"core_share_error_6" = "[SUIE10001]平台%@分享时,传入的参数currentViewController应该是nil或者是继承UIViewController的子类。 https://developer.umeng.com/docs/66632/detail/67032?um_channel=sdk"; +"core_auth_error_6" = "[SUIE10001]平台%@分享时,传入的参数currentViewController应该是nil或者是继承UIViewController的子类。 https://developer.umeng.com/docs/66632/detail/67032?um_channel=sdk"; +"core_getuserinfo_error_3" = "[SUIE10001]平台%@分享时,传入的参数currentViewController应该是nil或者是继承UIViewController的子类。 https://developer.umeng.com/docs/66632/detail/67032?um_channel=sdk"; + +//wechat +"wechat_auth_error_1" = "[SCE10002]请检查是否设置了微信的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; + +"wechat_share_error_1" = "[SCE10002]请检查是否设置了微信的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"wechat_share_error_2" = "[SCE10003]分享前,请检查微信是否安装。 https://developer.umeng.com/docs/66632/detail/67025?um_channel=sdk"; +"wechat_share_error_3" = "[SWE10001]当前的sdk不支持微信的OpenAPI,请更新最新的微信SDK。 https://developer.umeng.com/docs/66632/detail/67036?um_channel=sdk"; +"wechat_share_error_4" = "[SWE10002]微信分享不支持的分享类型,微信的分享类型为:文本,图片,网络链接,音乐链接,视频链接,Gif表情,文件。 https://developer.umeng.com/docs/66632/detail/67037?um_channel=sdk"; +"wechat_share_error_5" = "[SWE10003]下载UMShareImageObject的shareImage失败,请检查图片参数是否正确。(本地图片,请检查是否赋值,网络图片请检查是否为https,防止下载失败)。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; + +"wechat_shareWebPage_warn_1" = "[SWE10003]微信分享网页链接的时候,提供的缩略图为错误的下载url或者下载失败,具体的原因如下:%@。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; +"wechat_shareWebPage_warn_2" = "[SWE10003]微信分享网页链接的时候,提供的缩略图为错误的下载url或者下载失败。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; + +"wechat_shareImage_warn_1" = "[SWE10003]微信分享图片的时候,提供的缩略图为为错误的下载url或者下载失败,具体的原因如下:%@。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; +"wechat_shareImage_warn_2" = "[SWE10003]微信分享图片的时候,提供的缩略图为为错误的下载url或者下载失败。 https://developer.umeng.com/docs/66632/detail/67038?um_channel=sdk"; +// wechat info +"wechat_info_1" = "[SWI10004]分享面板中不显示微信。 https://developer.umeng.com/docs/66632/detail/67039?um_channel=sdk"; +"wechat_info_2" = "[SWI10005]如何获取微信code。 https://developer.umeng.com/docs/66632/detail/67040?um_channel=sdk"; +"wechat_info_3" = "[SWI10007]微信分享报错提示,请请检查微信是否安装。 https://developer.umeng.com/docs/66632/detail/67042?um_channel=sdk"; +"wechat_info_4" = "[SWI10008]微信授权登录提示该链接无法访问。 https://developer.umeng.com/docs/66632/detail/67043?um_channel=sdk"; +"wechat_info_5" = "[SWI10009]微信分享报错'由于invalid_app无法分享到微信。 https://developer.umeng.com/docs/66632/detail/67044?um_channel=sdk"; + +//qq +"qq_auth_error_1" = "[SCE10002]请检查是否设置了QQ的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"qq_auth_error_2" = "[SQE10001]授权失败,点击qq授权没有跳转,请查看是否设置了appid,查看初始化函数:[[UMSocialManager defaultManager] setPlaform:UMSocialPlatformType_QQ appKey:??? appSecret:nil redirectURL:???];。 https://developer.umeng.com/docs/66632/detail/67045?um_channel=sdk"; + +"qq_getuserinfo_error_1" = "[SCE10002]请检查是否设置了QQ的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"qq_getuserinfo_info_1" = "[SCE10004]可设置获得用户信息时是否清除缓存,通过UMSocialGlobal的isClearCacheWhenGetUserInfo变量来改变,默认是每次都清除用户的授权缓存。 https://developer.umeng.com/docs/66632/detail/67026?um_channel=sdk"; + + +"qq_share_error_1" = "[SCE10002]请检查是否设置了QQ的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"qq_share_error_2" = "[SCE10003]请检查是否安装了QQ。 https://developer.umeng.com/docs/66632/detail/67025?um_channel=sdk"; +"qq_share_error_3" = "[SQE10002]请检查当前的SDK是否支持API调用,如果不能请升级SDK或者QQ的版本。 https://developer.umeng.com/docs/66632/detail/67046?um_channel=sdk"; +"qq_share_error_4" = "[SQE10003]QQ分享不支持的分享类型,QQ的分享类型为:文本,图片,网络链接,音乐链接,视频链接。 https://developer.umeng.com/docs/66632/detail/67047?um_channel=sdk"; + +"qq_shareWebPage_warn_1" = "[SQE10004]QQ分享网页链接的时提供的缩略图为错误的下载url或者下载失败,具体的原因如下:%@。 https://developer.umeng.com/docs/66632/detail/67048?um_channel=sdk"; +"qq_shareWebPage_warn_2" = "[SQE10004]QQ分享网页链接的时提供的缩略图为错误的下载url或者下载失败。 https://developer.umeng.com/docs/66632/detail/67048?um_channel=sdk"; +//info +"qq_info_1" = "[SQI10005]QQ和TIM平台混淆问题。 https://developer.umeng.com/docs/66632/detail/67049?um_channel=sdk"; +"qq_info_2" = "[SQI10006]QQ登录时显示的应用名如何设置。 https://developer.umeng.com/docs/66632/detail/67050?um_channel=sdk"; +"qq_info_3" = "[SQI10007]QQ登录提示错误110406。 https://developer.umeng.com/docs/66632/detail/67051?um_channel=sdk"; +"qq_info_4" = "[SQI10008]QQ报错 100008 client request's app is not existed。 https://developer.umeng.com/docs/66632/detail/67053?um_channel=sdk"; + + +//sina +"sina_auth_error_1" = "[SCE10002]请检查是否设置了sina的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; + +"sina_getuserinfo_error_1" = "[SCE10002]请检查是否设置了sina的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; + +"sina_share_error_1" = "[SCE10002]请检查是否设置了sina的URLSchema。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +"sina_share_error_2" = "[SSE10001]新浪分享不支持的分享类型,新浪的分享类型为:文本,图片,图文,网络链接,音乐链接,视频链接。 https://developer.umeng.com/docs/66632/detail/67329?um_channel=sdk"; +"sina_shareWebPage_error_1"="[SSE10002]新浪分享webpage类型(需要强制加入缩略图)错误,具体原因如下:%@。 https://developer.umeng.com/docs/66632/detail/67054?um_channel=sdk"; +"sina_shareText_Info_1" = "[SSI10003]新浪文本分享最大的字是140个,如果超过就不能分享成功,sdk默认开启截断功能,如果需要停止截断需要在调用分享前加入代码[UMSocialGlobal shareInstance].isTruncateShareText=NO。 https://developer.umeng.com/docs/66632/detail/67055?um_channel=sdk"; +//info +"sina_info_1" = "[SSI10004]微博分享 网页(WebPage)类型,链接在微博只显示为'网页链接'的文字。 https://developer.umeng.com/docs/66632/detail/67056?um_channel=sdk"; +"sina_info_2" = "[SSI10005]微博登录报错'sso package or sign error'。 https://developer.umeng.com/docs/66632/detail/67058?um_channel=sdk"; +"sina_info_3" = "[SSI10006]微博授权实现关注官方微博功能。 https://developer.umeng.com/docs/66632/detail/67059?um_channel=sdk"; +"sina_info_4" = "[SSI10007]微博报错 redirect url mismatch。 https://developer.umeng.com/docs/66632/detail/67060?um_channel=sdk"; + +// 钉钉支付宝 +// info +"ding_error_1" = "[SDE10001]支付宝/钉钉返回鉴权失败。 https://developer.umeng.com/docs/66632/detail/67062?um_channel=sdk"; + +//facebook +"facebook_share_error_1" = "[SFE10001]facebook分享不支持的分享类型,facebook的分享类型为:文本,图片,网络链接,音乐链接,视频链接。(新版的facebook采用的是对话框的形式分享的,如果设置文本的话需要有publish_actions权限调用OpenAPI)。 https://developer.umeng.com/docs/66632/detail/67064?um_channel=sdk"; +//error +"facebook_info_2" = "[SFI10002]FAQ: Facebook/Twitter分享点击分享后没有进入分享编辑页。 https://developer.umeng.com/docs/66632/detail/67065?um_channel=sdk"; +"facebook_info_3" = "[SFE10003]FAQ: Facebook分享失败,提示missing publish_actions permissions。 https://developer.umeng.com/docs/66632/detail/67066?um_channel=sdk"; + +//twitter +"twitter_auth_error_1" = "[SCE10002]请检查是否设置了 Twitter 的 URLScheme。 https://developer.umeng.com/docs/66632/detail/67024?um_channel=sdk"; +//info +"twitter_info_1" = "[STI10001]Twitter如何获取TokenSecret。 https://developer.umeng.com/docs/66632/detail/67068?um_channel=sdk"; +"twitter_info_2" = "[STE10002]FAQ: Twitter 分享报错401。 https://developer.umeng.com/docs/66632/detail/67069?um_channel=sdk"; + +// --------- sdk 内 log +"core_version" = "UMShare版本号:%@。"; +// 实现handler协议提示 +"core_platform_warn_2" = "第三方或自定义平台异常:%@ > 未实现相应方法:@selector(umSocial_setAppKey:withAppSecret:withRedirectURL:)"; +"core_auth_error_2" = "未实现第三方或自定义协议方法@selector(umSocial_AuthorizeWithUserInfo:withViewController:withCompletionHandler:):%@"; +"core_auth_error_3" = "未实现第三方或自定义协议方法@selector(umSocial_cancelAuthWithCompletionHandler:):%@"; +"core_auth_error_5" = "未实现协议方法@selector(umSocial_AuthorizeWithUserInfo:withCompletionHandler:):%@"; +"core_getuserinfo_error_2" = "未实现第三方或自定义协议方法@selector(umSocial_RequestForUserProfileWithViewController:completion:):%@"; +"core_share_error_3" = "未实现第三方或自定义协议方法@selector(umSocial_ShareWithObject:withCompletionHandler:):%@"; + diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMSocialPromptLocalizable.strings.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMSocialPromptLocalizable.strings.meta new file mode 100644 index 00000000..807fce38 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.bundle/zh-Hans.lproj/UMSocialPromptLocalizable.strings.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 3a80739e0075f4a9a89f3afd6b46164d +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework.meta new file mode 100644 index 00000000..0d997e58 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework.meta @@ -0,0 +1,27 @@ +fileFormatVersion: 2 +guid: 4dd249a89962d45e0a39587d9eb40daa +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/1.0.0_2b57438b90_20171227114643 b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/1.0.0_2b57438b90_20171227114643 new file mode 100644 index 00000000..3eefcb9d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/1.0.0_2b57438b90_20171227114643 @@ -0,0 +1 @@ +1.0.0 diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/1.0.0_2b57438b90_20171227114643.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/1.0.0_2b57438b90_20171227114643.meta new file mode 100644 index 00000000..390acd99 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/1.0.0_2b57438b90_20171227114643.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 62c0a24d9eb914220860e87f980371b3 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers.meta new file mode 100644 index 00000000..46763c98 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a0bd27ce008524bd0a0241a368326897 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogHeaders.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogHeaders.h new file mode 100644 index 00000000..efa1dedf --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogHeaders.h @@ -0,0 +1,12 @@ +// +// UMCommonLogHeaders.h +// UMCommonLog +// +// Created by 张军华 on 2017/12/4. +// Copyright © 2017年 张军华. All rights reserved. +// + +#import + + +#import diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogHeaders.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogHeaders.h.meta new file mode 100644 index 00000000..006eafca --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogHeaders.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 8fa2d15ed35414a8e88b44fa5b35bc4a +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogManager.h b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogManager.h new file mode 100644 index 00000000..324d865f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogManager.h @@ -0,0 +1,18 @@ +// +// UMCommonLogManager.h +// testUMCommonLog +// +// Created by 张军华 on 2017/11/28. +// Copyright © 2017年 张军华. All rights reserved. +// + +#import + + + +@interface UMCommonLogManager : NSObject + ++(void) setUpUMCommonLogManager; + + +@end diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogManager.h.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogManager.h.meta new file mode 100644 index 00000000..eeea20e5 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Headers/UMCommonLogManager.h.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 329c8c9e562954d5f9533facde17a12b +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Info.plist b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Info.plist new file mode 100644 index 00000000..425da774 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Info.plist differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Info.plist.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Info.plist.meta new file mode 100644 index 00000000..336da63f --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: c8ddf9e47aa9a4bc3b588227ad50f925 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules.meta new file mode 100644 index 00000000..00a80cbe --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c2de94d81639943c888f9256c82826c8 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules/module.modulemap b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules/module.modulemap new file mode 100644 index 00000000..c0e44f61 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules/module.modulemap @@ -0,0 +1,6 @@ +framework module UMCommonLog { + umbrella header "UMCommonLog.h" + + export * + module * { export * } +} diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules/module.modulemap.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules/module.modulemap.meta new file mode 100644 index 00000000..e3ec29fb --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/Modules/module.modulemap.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 42e6c309f70c540b6b48dc7d5d2c25ae +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/UMCommonLog b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/UMCommonLog new file mode 100644 index 00000000..af795845 Binary files /dev/null and b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/UMCommonLog differ diff --git a/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/UMCommonLog.meta b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/UMCommonLog.meta new file mode 100644 index 00000000..9b27b219 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/Plugins/iOS/umcommonlog/umcommonlog_ios_2.0.0/UMCommonLog.framework/UMCommonLog.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 2f1ac9f6528614743a28cb2464c7db1d +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics.meta b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics.meta new file mode 100644 index 00000000..8fec1e2c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: bb6d209d4e8824d9f87ac109828e89e4 +folderAsset: yes +timeCreated: 1426488285 +licenseType: Free +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts.meta b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts.meta new file mode 100644 index 00000000..cb7c6273 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 6b980f645e5de44b3b1832136f232a33 +folderAsset: yes +timeCreated: 1426661499 +licenseType: Free +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/Analytics.cs b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/Analytics.cs new file mode 100644 index 00000000..f80f229c --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/Analytics.cs @@ -0,0 +1,577 @@ + +// Created by ZhuCong on 1/1/14. +// Copyright 2014 Umeng.com . All rights reserved. +// +//#undef UNITY_EDITOR + +using UnityEngine; +using System; +using System.Runtime.InteropServices; +using System.Collections; +using System.Collections.Generic; +using System.Text; + + + + + +namespace Umeng +{ + + public partial class Analytics + { + + + +#if UNITY_ANDROID + static bool hasInit = false; + protected static AndroidJavaClass UMConfigure = new AndroidJavaClass("com.umeng.commonsdk.UMConfigure"); + protected static AndroidJavaClass Agent = new AndroidJavaClass("com.umeng.analytics.game.UMGameAgent"); + protected static AndroidJavaObject Context = new AndroidJavaClass("com.unity3d.player.UnityPlayer").GetStatic("currentActivity"); + + +#endif + + private const string Version = "3.2"; + public enum DeviceType + { + Phone = 0, + Box = 1 + } + + + + + + + + + + + + + //iOS Android Universal API + + + + // + /// + /// 开始友盟统计 默认发送策略为启动时发送 + /// + /// 友盟appKey + /// 渠道名称 + /// + /// + public static void StartWithAppKeyAndChannelId(string appKey, string channelId) + { +#if UNITY_EDITOR + //Debug.LogWarning("友盟统计在iOS/Android 真机上才会向友盟后台服务器发送事件 请在真机上测试"); + +#elif UNITY_IPHONE + + + UMCommonSetAppkeyAndChannel(appKey,channelId); + //iOS 必须设置 android 无此API + _SetScenarioType(); + + +#elif UNITY_ANDROID + + + + + UMCommonSetAppkeyAndChannel(appKey,channelId); + //2次init 第一次UMConfigureinit在UMCommonSetAppkeyAndChannel方法内,第二次在这里UMGameAgent.init() + Agent.CallStatic("init",Context); + + + if(!hasInit) + { + //Debug.LogWarning("onResume"); + onResume(); + + AddUmengAndroidLifeCycleCallBack(); + hasInit = true; + } + + +#endif + } + + private static void UMCommonSetAppkeyAndChannel(string appkey, string channelId,DeviceType deviceType=DeviceType.Phone,string pushSecret=null) + { + +#if UNITY_EDITOR + + +#elif UNITY_IPHONE + + + _SetWrapperTypeAndVersion("Unity", Version); + _UMCommonSetAppkeyAndChannel(appkey, channelId); + +#elif UNITY_ANDROID + + UMConfigure.CallStatic("setWraperType","Unity",Version); + UMConfigure.CallStatic("init",Context,appkey,channelId,(int)deviceType,pushSecret); +#endif + } + + + /// + /// 设置是否打印sdk的信息,默认不开启 + /// + /// 设置为true,Umeng SDK 会输出日志信息,记得release产品时要设置回false. + /// + public static void SetLogEnabled(bool value) + { +#if UNITY_EDITOR + //Debug.Log("SetLogEnabled"); +#elif UNITY_IPHONE + _SetLogEnabled(value); +#elif UNITY_ANDROID + + + UMConfigure.CallStatic("setLogEnabled",value); +#endif + } + + //使用前,请先到友盟App管理后台的设置->编辑自定义事件 中添加相应的事件ID,然后在工程中传入相应的事件ID + //eventId、attributes中key和value都不能使用空格和特殊字符,且长度不能超过255个字符(否则将截取前255个字符) + //id, ts, du是保留字段,不能作为eventId及key的名称 + + + /// + /// 基本事件 + /// + /// 友盟后台设定的事件Id + public static void Event(string eventId) + { +#if UNITY_EDITOR + //Debug.Log("Event"); +#elif UNITY_IPHONE + _Event(eventId); +#elif UNITY_ANDROID + Agent.CallStatic("onEvent", Context, eventId); +#endif + } + //不同的标签会分别进行统计,方便同一事件的不同标签的对比,为nil或空字符串时后台会生成和eventId同名的标签. + + + /// + /// 基本事件 + /// + /// 友盟后台设定的事件Id + /// 分类标签 + + public static void Event(string eventId, string label) + { +#if UNITY_EDITOR + //Debug.Log("Event"); +#elif UNITY_IPHONE + _EventWithLabel(eventId, label); +#elif UNITY_ANDROID + Agent.CallStatic("onEvent", Context, eventId, label); +#endif + } + + + + + /// + /// 属性事件 + /// + /// 友盟后台设定的事件Id + /// 属性中的Key-Vaule Pair不能超过10个 + public static void Event(string eventId, Dictionary attributes) + { +#if UNITY_EDITOR + //Debug.Log("Event"); +#elif UNITY_IPHONE + _EventWithAttributes(eventId, DictionaryToJson(attributes)); +#elif UNITY_ANDROID + Agent.CallStatic("onEvent", Context, eventId, ToJavaHashMap(attributes)); +#endif + + } + + + /// + /// 页面时长统计,记录某个页面被打开多长时间 + /// + /// 被统计view名称 + /// + public static void PageBegin(string pageName) + { +#if UNITY_EDITOR + //Debug.Log("PageBegin"); +#elif UNITY_IPHONE + _BeginLogPageView(pageName); +#elif UNITY_ANDROID + Agent.CallStatic("onPageStart", pageName); +#endif + } + + /// + /// 页面时长统计,记录某个页面被打开多长时间 + /// 与PageBegin配对使用 + /// + /// 被统计view名称 + /// + public static void PageEnd(string pageName) + { +#if UNITY_EDITOR + //Debug.Log("PageEnd"); +#elif UNITY_IPHONE + _EndLogPageView(pageName); +#elif UNITY_ANDROID + Agent.CallStatic("onPageEnd", pageName); +#endif + } + + /// + /// 自定义事件 — 计算事件数 + /// + public static void Event(string eventId, Dictionary attributes, int value) + { + try + { + if (attributes == null) + attributes = new System.Collections.Generic.Dictionary(); + if (attributes.ContainsKey("__ct__")) + { + attributes["__ct__"] = value.ToString(); + Event(eventId, attributes); + } + else + { + attributes.Add("__ct__", value.ToString()); + Event(eventId, attributes); + attributes.Remove("__ct__"); + } + + } + catch (Exception) + { + } + } + + + + + + + + + public static string GetTestDeviceInfo() + { +#if UNITY_EDITOR + //Unity Editor 模式下 返回null 请在iOS/Anroid真机上测试 + //Debug.Log("GetDeviceInfo return null"); + return null; +#elif UNITY_IPHONE + return _GetDeviceID(); +#elif UNITY_ANDROID + + Debug.Log("GetDeviceInfo return "); + return UMConfigure.CallStatic("getTestDeviceInfo", Context)[0]; + +#else + return null; + +#endif + + } + + //设置是否对日志信息进行加密, 默认false(不加密). + //value 设置为true, SDK会将日志信息做加密处理 + + public static void SetLogEncryptEnabled(bool value) + { + #if UNITY_EDITOR + //Debug.Log("SetLogEncryptEnabled"); + #elif UNITY_IPHONE + _SetEncryptEnabled(value); + #elif UNITY_ANDROID + UMConfigure.CallStatic("setEncryptEnabled",value); + #endif + + + } + + + public static void SetLatency(int value) + { + #if UNITY_EDITOR + //Debug.Log("SetLatency"); + #elif UNITY_IPHONE + //_SetLatency(value); + #elif UNITY_ANDROID + Agent.CallStatic("setLatencyWindow", (long)value); + #endif + + } + + + + + + //Android Only + +#if UNITY_ANDROID + + + + //设置Session时长 + public static void SetContinueSessionMillis(long milliseconds) + { +#if UNITY_EDITOR + //Debug.Log("setContinueSessionMillis"); +#else + Agent.CallStatic("setSessionContinueMillis", milliseconds); +#endif + } + + + + /* + android6.0中采集mac方式变更,新增接口 public static void setCheckDevice(boolean enable) 该接口默认参数是true,即采集mac地址, + 但如果开发者需要在googleplay发布,考虑到审核风险,可以调用该接口,参数设置为 false 就不会采集mac地址。 + + */ + public static void SetCheckDevice(bool value) + { +#if UNITY_EDITOR + +#else + Agent.CallStatic("setCheckDevice", value); +#endif + + } + + + + + + + + + +#endif + + + + //iOS Only +#if UNITY_IPHONE + + + + /// + /// 页面时长统计,记录某个view被打开多长时间,与调用PageBegin,PageEnd计时等价 + /// + /// 被统计view名称 + /// 时长单位为秒 + /// + public static void LogPageViewWithSeconds(string pageName, int seconds) + { +#if UNITY_EDITOR + //Debug.Log("LogPageViewWithSeconds"); +#else + _LogPageViewWithSeconds(pageName, seconds); +#endif + } + + + + /// + /// 判断设备是否越狱,判断方法根据 apt和Cydia.app的path来判断 + /// + /// 是否越狱 + public static bool IsJailBroken() + { +#if UNITY_EDITOR + //always return false in UNITY_EDITOR mode + //Debug.Log("IsJailBroken always return false in UNITY_EDITOR mode"); + return false; +#else + return _IsJailBroken(); +#endif + } + + /// + /// 判断你的App是否被破解 + /// + /// 是否破解 + public static bool IsPirated() + { +#if UNITY_EDITOR + //always return false in UNITY_EDITOR mode + //Debug.Log("IsPirated always return false in UNITY_EDITOR mode"); + return false; +#else + return _IsPirated(); +#endif + } + + + + + + + +#endif + + + + + + + + + + #region Wrapper + + + private static void AddUmengAndroidLifeCycleCallBack() + { + GameObject go = new GameObject(); + go.AddComponent(); + go.name = "UmengManager"; + } + +#if UNITY_ANDROID + + public static void onResume() + { +#if UNITY_EDITOR + +#else + Agent.CallStatic("onResume", Context); +#endif + } + + + + public static void onPause() + { +#if UNITY_EDITOR + +#else + Agent.CallStatic("onPause", Context); +#endif + } + + public static void onKillProcess() + { +#if UNITY_EDITOR + +#else + Agent.CallStatic("onKillProcess", Context); + +#endif + } + + + + + + + + + +#endif + + +#if UNITY_IPHONE && !UNITY_EDITOR + + + + + + + static string DictionaryToJson(Dictionary dict) + { + + var builder = new StringBuilder("{"); + foreach (KeyValuePair kv in dict) + { + builder.AppendFormat("\"{0}\":\"{1}\",", kv.Key, kv.Value); + } + builder[builder.Length - 1] = '}'; + return builder.ToString(); + + + } + + + + + + [DllImport("__Internal")] + private static extern void _SetWrapperTypeAndVersion(string wrapperType,string wrapperVersion); + + [DllImport("__Internal")] + private static extern void _SetLogEnabled(bool value); + + [DllImport("__Internal")] + private static extern void _SetScenarioType(); + + [DllImport("__Internal")] + private static extern void _UMCommonSetAppkeyAndChannel(string appkey, string channelId); + + + + + + + + + + [DllImport("__Internal")] + private static extern void _Event(string eventId); + + + + [DllImport("__Internal")] + private static extern void _EventWithLabel(string eventId, string label); + + + + [DllImport("__Internal")] + private static extern void _EventWithAttributes(string eventId, string jsonstring); + + + + + + [DllImport("__Internal")] + private static extern void _LogPageViewWithSeconds(string pageName, int seconds); + + [DllImport("__Internal")] + private static extern void _BeginLogPageView(string pageName); + + [DllImport("__Internal")] + private static extern void _EndLogPageView(string pageName); + + [DllImport("__Internal")] + private static extern bool _IsJailBroken(); + + [DllImport("__Internal")] + private static extern bool _IsPirated(); + + + [DllImport("__Internal")] + private static extern string _GetDeviceID(); + + + + [DllImport("__Internal")] + private static extern void _SetEncryptEnabled(bool value); + + + + +#endif + #endregion + } +} diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/Analytics.cs.meta b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/Analytics.cs.meta new file mode 100644 index 00000000..aabdb6ac --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/Analytics.cs.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: d5d1afe51af5449a4aa6c8c01222f267 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/DplusAgent.cs b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/DplusAgent.cs new file mode 100644 index 00000000..61735824 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/DplusAgent.cs @@ -0,0 +1,294 @@ +//#undef UNITY_EDITOR + +using UnityEngine; +using System; +using System.Runtime.InteropServices; +using System.Collections; +using System.Collections.Generic; +using System.Text; + + + +namespace Umeng +{ + + public partial class Analytics + { + + +#if UNITY_ANDROID + + private static AndroidJavaObject AndroidJavaJsonObject(JSONObject jSONObject) + { + return new AndroidJavaObject("org.json.JSONObject", jSONObject.ToString()); + } + + private static JSONObject jsonObjectFromJava(AndroidJavaObject androidJavaJsonObject) + { + return (JSONObject)JSONNode.Parse(androidJavaJsonObject.Call("toString")); + } + + private static AndroidJavaObject ToJavaObject(object obj) + { + if (obj is int) + { + return new AndroidJavaObject("java.lang.Integer", obj); + } + else if (obj is long) + { + return new AndroidJavaObject("java.lang.Long", obj); + } + + else if (obj is float) + { + return new AndroidJavaObject("java.lang.Float", obj); + + } + else if (obj is double) + { + return new AndroidJavaObject("java.lang.Double", obj); + } + else if (obj is string) + { + return new AndroidJavaObject("java.lang.String", obj); + + } + else if(obj is bool) + { + + return new AndroidJavaObject("java.lang.Integer", Convert.ToInt32((bool)obj)); + + } + else + { + Debug.Log("不支持加入" + obj.GetType()+"类型,此kv对被丢弃"); + return null; + } + + + + + } + + + + private static AndroidJavaObject ToJavaHashMap(Dictionary dic) + { + var hashMap = new AndroidJavaObject("java.util.HashMap"); + + + foreach (var kv in dic) + { + var vauleObj = ToJavaObject(kv.Value); + if (vauleObj != null) + { + + hashMap.Call("put", kv.Key, vauleObj); + } + + } + + return hashMap; + } + private static AndroidJavaObject ToJavaHashMap(Dictionary dic) + { + var hashMap = new AndroidJavaObject("java.util.HashMap"); + foreach (var entry in dic) + { + hashMap.Call("put", entry.Key, entry.Value); + } + return hashMap; + + } + + private static AndroidJavaObject ToJavaList(String[] list) + { + var javaList = new AndroidJavaObject("java.util.ArrayList"); + + + foreach (String str in list) + { + javaList.Call("add", str); + } + + return javaList; + } + +#elif UNITY_IPHONE + + private static string ToJsonStr(Dictionary dict) + { + + var builder = new StringBuilder("{"); + foreach (KeyValuePair kv in dict) + { + if(kv.Value is string) + { + builder.AppendFormat("\"{0}\":\"{1}\",", kv.Key, kv.Value); + } + else if(kv.Value is float || kv.Value is double|| kv.Value is int || kv.Value is long) + { + builder.AppendFormat("\"{0}\":{1},", kv.Key, kv.Value.ToString()); + } + else if( kv.Value is bool) + { + builder.AppendFormat("\"{0}\":{1},", kv.Key, Convert.ToInt32(kv.Value)); + } + else + { + Debug.Log("不支持此类型"); + + } + + + + } + builder[builder.Length - 1] = '}'; + return builder.ToString(); + + + } +#endif + + + + + public static void EventObject(String eventID,Dictionary dict) + { +#if UNITY_EDITOR + +#elif UNITY_IPHONE + _EventObject(eventID, ToJsonStr(dict)); +#elif UNITY_ANDROID + Agent.CallStatic("onEventObject", Context, eventID, ToJavaHashMap(dict)); +#endif + + } + + + + + public static void RegisterPreProperties(JSONObject jsonObject) + { + JSONObject filteredJsonObject = new JSONObject(); + + foreach (KeyValuePair kv in jsonObject) + { + if (kv.Value.IsObject || kv.Value.IsArray) + { + Debug.LogError("不支持加入Object/Array类型,此kv对被丢弃"); + + + } + else if ( kv.Value.IsBoolean) + { + + filteredJsonObject.Add(kv.Key, Convert.ToInt32(kv.Value.AsBool)); + + + } + else + { + filteredJsonObject.Add(kv.Key, kv.Value); + } + + + + } + + + +#if UNITY_EDITOR + +#elif UNITY_IPHONE + _RegisterSuperProperty(filteredJsonObject.ToString()); +#elif UNITY_ANDROID + + Agent.CallStatic("registerPreProperties", Context, AndroidJavaJsonObject(filteredJsonObject)); +#endif + + } + + + + public static void UnregisterPreProperty(String propertyName) + { +#if UNITY_EDITOR + +#elif UNITY_IPHONE + _UnregisterSuperProperty(propertyName); +#elif UNITY_ANDROID + Agent.CallStatic("unregisterPreProperty", Context, propertyName); +#endif + + } + + + + + + public static JSONObject GetPreProperties() + { +#if UNITY_EDITOR + return null; +#elif UNITY_IPHONE + return (JSONObject)JSONObject.Parse(_GetSuperProperties()); +#elif UNITY_ANDROID + return jsonObjectFromJava( Agent.CallStatic("getPreProperties", Context) ); + +#endif + + + } + public static void ClearPreProperties() + { +#if UNITY_EDITOR + +#elif UNITY_IPHONE + _ClearSuperProperties(); +#elif UNITY_ANDROID + Agent.CallStatic("clearPreProperties", Context); +#endif + + } + + + public static void SetFirstLaunchEvent(string[] trackID) + { +#if UNITY_EDITOR + +#elif UNITY_IPHONE + + _SetFirstLaunchEvent(trackID, trackID.Length); +#elif UNITY_ANDROID + + Agent.CallStatic("setFirstLaunchEvent", Context, ToJavaList(trackID)); +#endif + + + } + +#if UNITY_IPHONE + [DllImport("__Internal")] + private static extern void _EventObject(string eventID, string jsonStr); + [DllImport("__Internal")] + private static extern void _RegisterSuperProperty(string jsonStr); + [DllImport("__Internal")] + private static extern void _UnregisterSuperProperty(string propertyName); + [DllImport("__Internal")] + private static extern string _GetSuperProperties(); + [DllImport("__Internal")] + private static extern void _ClearSuperProperties(); + [DllImport("__Internal")] + private static extern void _SetFirstLaunchEvent(string[] propertyName,int len); +#endif + + + } + + + + + + +} diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/DplusAgent.cs.meta b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/DplusAgent.cs.meta new file mode 100644 index 00000000..9dcd7686 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/DplusAgent.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 60b6ac15bffd14b25a7a2d1dd9a4ee03 +timeCreated: 1490351292 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/GA.cs b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/GA.cs new file mode 100644 index 00000000..88661caa --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/GA.cs @@ -0,0 +1,419 @@ + +// Created by ZhuCong on 1/1/14. +// Copyright 2014 Umeng.com . All rights reserved. + +#undef UNITY_EDITOR + +using System; +using UnityEngine; +using System.Runtime.InteropServices; + + +namespace Umeng +{ + + /// + /// 友盟游戏统计 + /// + public class GA :Analytics + { + + + public enum Gender + { + Unknown = 0, + Male = 1, + Female = 2 + } + + /// + /// 设置玩家等级 + /// + /// 玩家等级 + public static void SetUserLevel(int level) + { + + #if UNITY_EDITOR + //Debug.Log("SetUserLevel"); + #elif UNITY_IPHONE + _SetUserLevel(level); + #elif UNITY_ANDROID + Agent.CallStatic("setPlayerLevel", level); + #endif + + } + + + + + /// + /// 设置玩家属性 + /// + /// 玩家Id + /// 性别 + /// 年龄 + /// 来源 + [System.Obsolete("SetUserInfo已弃用, 请使用ProfileSignIn")] + public static void SetUserInfo(string userId, Gender gender, int age, string platform) + { +#if UNITY_EDITOR + //Debug.Log("SetUserInfo"); +#elif UNITY_IPHONE + _SetUserInfo(userId, (int)gender, age, platform); +#elif UNITY_ANDROID + Agent.CallStatic("setPlayerInfo",userId, age, (int)gender, platform); +#endif + + + } + + + + + + + /// + /// 玩家进入关卡 + /// + /// 关卡 + public static void StartLevel(string level) + { + +#if UNITY_EDITOR + //Debug.Log("StartLevel"); +#elif UNITY_IPHONE + _StartLevel(level); +#elif UNITY_ANDROID + Agent.CallStatic("startLevel",level); +#endif + } + + /// + /// 玩家通过关卡 + /// + /// 如果level设置为null 则为当前关卡 + + public static void FinishLevel(string level) + { + +#if UNITY_EDITOR + //Debug.Log("FinishLevel"); +#elif UNITY_IPHONE + _FinishLevel(level); +#elif UNITY_ANDROID + Agent.CallStatic("finishLevel",level); +#endif + } + + /// + /// 玩家未通过关卡 + /// + /// 如果level设置为null 则为当前关卡 + public static void FailLevel(string level) + { + +#if UNITY_EDITOR + //Debug.Log("FailLevel"); +#elif UNITY_IPHONE + _FailLevel(level); +#elif UNITY_ANDROID + Agent.CallStatic("failLevel",level); +#endif + } + + + + + /// + /// Source9 到Source 20 请在友盟后台网站设置 对应的定义 + /// + public enum PaySource + { + AppStore = 1, + 支付宝 = 2, + 网银 = 3, + 财付通 = 4, + 移动 = 5, + 联通 = 6, + 电信 = 7, + Paypal = 8, + Source9, + Source10, + Source11, + Source12, + Source13, + Source14, + Source15, + Source16, + Source17, + Source18, + Source19, + Source20, + Source21, + Source22, + Source23, + Source24, + Source25, + Source26, + Source27, + Source28, + Source29, + Source30 + + + } + /// + /// 游戏中真实消费(充值)的时候调用此方法 + /// + /// 本次消费金额 + /// 来源 + /// 本次消费等值的虚拟币 + public static void Pay(double cash, PaySource source, double coin) + { + +#if UNITY_EDITOR + //Debug.Log("Pay"); +#elif UNITY_IPHONE + _PayCashForCoin(cash,(int)source,coin); +#elif UNITY_ANDROID + Agent.CallStatic("pay",cash , coin, (int)source); +#endif + } + + /// + /// 游戏中真实消费(充值)的时候调用此方法 + /// + /// 本次消费金额 + /// 来源:AppStore = 1,支付宝 = 2,网银 = 3,财付通 = 4,移动 = 5,联通 = 6,电信 = 7,Paypal = 8, + /// 9~100对应渠道请到友盟后台设置本次消费的途径,网银,支付宝 等 + /// 本次消费等值的虚拟币 + public static void Pay(double cash, int source, double coin) + { + if (source < 1 || source > 100) { + throw new System.ArgumentException (); + } + #if UNITY_EDITOR + //Debug.Log("Pay"); + #elif UNITY_IPHONE + _PayCashForCoin(cash,source,coin); + #elif UNITY_ANDROID + Agent.CallStatic("pay",cash , coin, source); + #endif + } + + /// + /// 玩家支付货币购买道具 + /// + /// 真实货币数量 + /// 支付渠道 + /// 道具名称 + /// 道具数量 + /// 道具单价 + public static void Pay(double cash, PaySource source, string item, int amount, double price) + { + +#if UNITY_EDITOR + //Debug.Log("Pay"); +#elif UNITY_IPHONE + _PayCashForItem(cash,(int)source,item,amount,price); +#elif UNITY_ANDROID + Agent.CallStatic("pay",cash, item, amount, price, (int)source); +#endif + } + + + /// + /// 玩家使用虚拟币购买道具 + /// + /// 道具名称 + /// 道具数量 + /// 道具单价 + + public static void Buy(string item, int amount, double price) + { + +#if UNITY_EDITOR + //Debug.Log("Buy"); +#elif UNITY_IPHONE + _Buy(item,amount,price); +#elif UNITY_ANDROID + Agent.CallStatic("buy", item, amount, price); +#endif + } + + + /// + /// 玩家使用虚拟币购买道具 + /// + /// 道具名称 + /// 道具数量 + /// 道具单价 + public static void Use(string item, int amount, double price) + { + +#if UNITY_EDITOR + //Debug.Log("Use"); +#elif UNITY_IPHONE + _Use(item, amount, price); +#elif UNITY_ANDROID + Agent.CallStatic("use", item, amount, price); +#endif + } + + + /// + /// Source4 到Source 10 请在友盟后台网站设置 对应的定义 + /// + public enum BonusSource + { + + 玩家赠送 = 1, + Source2 =2, + Source3 =3, + Source4, + Source5, + Source6, + Source7, + Source8, + Source9, + Source10, + + } + /// + /// 玩家获虚拟币奖励 + /// + /// 虚拟币数量 + /// 奖励方式 + public static void Bonus(double coin, BonusSource source) + { + +#if UNITY_EDITOR + //Debug.Log("Bonus"); +#elif UNITY_IPHONE + _BonusCoin(coin, (int)source); +#elif UNITY_ANDROID + Agent.CallStatic("bonus", coin, (int)source); +#endif + } + + + /// + /// 玩家获道具奖励 + /// + /// 道具名称 + /// 道具数量 + /// 道具单价 + /// 奖励方式 + /// + + public static void Bonus(string item, int amount, double price, BonusSource source) + { + +#if UNITY_EDITOR + //Debug.Log("Bonus"); +#elif UNITY_IPHONE + _BonusItem(item, amount, price, (int)source); +#elif UNITY_ANDROID + Agent.CallStatic("bonus", item, amount, price, (int)source); +#endif + } + + //使用sign-In函数后,如果结束该userId的统计,需要调用ProfileSignOff函数 + public static void ProfileSignIn(string userId) + { + #if UNITY_EDITOR + //Debug.Log("ProfileSignIn"); + #elif UNITY_IPHONE + _ProfileSignInWithPUID(userId); + #elif UNITY_ANDROID + Agent.CallStatic("onProfileSignIn", userId); + #endif + + + } + + //使用sign-In函数后,如果结束该userId的统计,需要调用ProfileSignOfff函数 + //provider : 不能以下划线"_"开头,使用大写字母和数字标识; 如果是上市公司,建议使用股票代码。 + + public static void ProfileSignIn(string userId,string provider) + { + #if UNITY_EDITOR + //Debug.Log("ProfileSignIn"); + #elif UNITY_IPHONE + _ProfileSignInWithPUIDAndProvider(userId,provider); + #elif UNITY_ANDROID + Agent.CallStatic("onProfileSignIn", provider,userId); + #endif + + + } + + //该结束该userId的统计 + public static void ProfileSignOff() + { + #if UNITY_EDITOR + //Debug.Log("ProfileSignOff"); + #elif UNITY_IPHONE + _ProfileSignOff(); + #elif UNITY_ANDROID + Agent.CallStatic("onProfileSignOff"); + #endif + + + + } + + +#if UNITY_IPHONE + + [DllImport("__Internal")] + private static extern void _SetUserLevel(int level); + + [DllImport("__Internal")] + private static extern void _SetUserInfo(string userId, int gender, int age, string platform); + + [DllImport("__Internal")] + private static extern void _StartLevel(string level); + + [DllImport("__Internal")] + private static extern void _FinishLevel(string level); + + [DllImport("__Internal")] + private static extern void _FailLevel(string level); + + [DllImport("__Internal")] + private static extern void _PayCashForCoin(double cash, int source, double coin); + + [DllImport("__Internal")] + private static extern void _PayCashForItem(double cash, int source, string item, int amount, double price); + + [DllImport("__Internal")] + private static extern void _Buy(string item, int amount, double price); + + [DllImport("__Internal")] + private static extern void _Use(string item, int amount, double price); + + [DllImport("__Internal")] + private static extern void _BonusCoin(double coin, int source); + + [DllImport("__Internal")] + private static extern void _BonusItem(string item, int amount, double price, int source); + + [DllImport("__Internal")] + private static extern void _ProfileSignInWithPUID (string puid); + + [DllImport("__Internal")] + private static extern void _ProfileSignInWithPUIDAndProvider(string puid,string provider); + + [DllImport("__Internal")] + private static extern void _ProfileSignOff(); + + + +#endif + + + + + } +} diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/GA.cs.meta b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/GA.cs.meta new file mode 100644 index 00000000..399ef48d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/GA.cs.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: f24a5fad2a9b94b63af6e0ccba3197a0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/JoyPacUmengBridge.cs b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/JoyPacUmengBridge.cs new file mode 100644 index 00000000..9230c07e --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/JoyPacUmengBridge.cs @@ -0,0 +1,61 @@ +using UnityEngine; +using System.Collections.Generic; + + +#if UNITY_ANDROID + +public class JoyPacUmengBridge +{ + public static JoyPacUmengBridge joyPacUmengBridge = new JoyPacUmengBridge(); + + private AndroidJavaObject unityUmengBridgeManager; + + private JoyPacUmengBridge() + { + if (Application.platform != RuntimePlatform.Android) + return; + unityUmengBridgeManager = new AndroidJavaObject("com.joypac.unityumengbridge.UnityUmengBridge"); + + } + + public static JoyPacUmengBridge getInstance() + { + return joyPacUmengBridge; + } + + public void initOnlineConfig() + { + + Debug.Log("initOnlineConfig strat"); + unityUmengBridgeManager.Call("uMenginitOnlineConfig"); + Debug.Log("initOnlineConfig end"); + + } + + public string getConfigParamsJson(string key) { + + Debug.Log("getConfigParamsJson strat"); + string value=unityUmengBridgeManager.Call("uMengGetParamJson", key); + Debug.Log("getConfigParamsJson end value:"+value); + return value; + } + + public void uMengEventWithLabel(string eventName,string label) + { + + Debug.Log("uMengEventWithLabel"); + unityUmengBridgeManager.Call("uMengEventWithLabel",eventName,label); + + } + + public void uMengEventWithAttributes(string eventName,string jsonStr) + { + Debug.Log("uMengEventWithAttributes"); + unityUmengBridgeManager.Call("uMengEventWithAttributes",eventName,jsonStr); + + } + + +} + +#endif diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/JoyPacUmengBridge.cs.meta b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/JoyPacUmengBridge.cs.meta new file mode 100644 index 00000000..5114291d --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/JoyPacUmengBridge.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e6c630d1ab4254047be8389b3cb123b0 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/SimpleJSON.cs b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/SimpleJSON.cs new file mode 100644 index 00000000..9dc637fd --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/SimpleJSON.cs @@ -0,0 +1,1398 @@ +//#define USE_SharpZipLib +#if !UNITY_WEBPLAYER +#define USE_FileIO +#endif +/* * * * * + * A simple JSON Parser / builder + * ------------------------------ + * + * It mainly has been written as a simple JSON parser. It can build a JSON string + * from the node-tree, or generate a node tree from any valid JSON string. + * + * If you want to use compression when saving to file / stream / B64 you have to include + * SharpZipLib ( http://www.icsharpcode.net/opensource/sharpziplib/ ) in your project and + * define "USE_SharpZipLib" at the top of the file + * + * Written by Bunny83 + * 2012-06-09 + * + * + * Features / attributes: + * - provides strongly typed node classes and lists / dictionaries + * - provides easy access to class members / array items / data values + * - the parser now properly identifies types. So generating JSON with this framework should work. + * - only double quotes (") are used for quoting strings. + * - provides "casting" properties to easily convert to / from those types: + * int / float / double / bool + * - provides a common interface for each node so no explicit casting is required. + * - the parser tries to avoid errors, but if malformed JSON is parsed the result is more or less undefined + * - It can serialize/deserialize a node tree into/from an experimental compact binary format. It might + * be handy if you want to store things in a file and don't want it to be easily modifiable + * + * + * 2012-12-17 Update: + * - Added internal JSONLazyCreator class which simplifies the construction of a JSON tree + * Now you can simple reference any item that doesn't exist yet and it will return a JSONLazyCreator + * The class determines the required type by it's further use, creates the type and removes itself. + * - Added binary serialization / deserialization. + * - Added support for BZip2 zipped binary format. Requires the SharpZipLib ( http://www.icsharpcode.net/opensource/sharpziplib/ ) + * The usage of the SharpZipLib library can be disabled by removing or commenting out the USE_SharpZipLib define at the top + * - The serializer uses different types when it comes to store the values. Since my data values + * are all of type string, the serializer will "try" which format fits best. The order is: int, float, double, bool, string. + * It's not the most efficient way but for a moderate amount of data it should work on all platforms. + * + * 2017-03-08 Update: + * - Optimised parsing by using a StringBuilder for token. This prevents performance issues when large + * string data fields are contained in the json data. + * - Finally refactored the badly named JSONClass into JSONObject. + * - Replaced the old JSONData class by distict typed classes ( JSONString, JSONNumber, JSONBool, JSONNull ) this + * allows to propertly convert the node tree back to json without type information loss. The actual value + * parsing now happens at parsing time and not when you actually access one of the casting properties. + * + * The MIT License (MIT) + * + * Copyright (c) 2012-2017 Markus Göbel + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * * * * */ +using System; +using System.Collections; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace Umeng +{ + public enum JSONNodeType + { + Array = 1, + Object = 2, + String = 3, + Number = 4, + NullValue = 5, + Boolean = 6, + None = 7, + } + + public abstract partial class JSONNode + { + #region common interface + + public virtual JSONNode this[int aIndex] { get { return null; } set { } } + + public virtual JSONNode this[string aKey] { get { return null; } set { } } + + public virtual string Value { get { return ""; } set { } } + + public virtual int Count { get { return 0; } } + + public virtual bool IsNumber { get { return false; } } + public virtual bool IsString { get { return false; } } + public virtual bool IsBoolean { get { return false; } } + public virtual bool IsNull { get { return false; } } + public virtual bool IsArray { get { return false; } } + public virtual bool IsObject { get { return false; } } + + public virtual void Add(string aKey, JSONNode aItem) + { + } + public virtual void Add(JSONNode aItem) + { + Add("", aItem); + } + + public virtual JSONNode Remove(string aKey) + { + return null; + } + + public virtual JSONNode Remove(int aIndex) + { + return null; + } + + public virtual JSONNode Remove(JSONNode aNode) + { + return aNode; + } + + public virtual IEnumerable Children + { + get + { + yield break; + } + } + + public IEnumerable DeepChildren + { + get + { + foreach (var C in Children) + foreach (var D in C.DeepChildren) + yield return D; + } + } + + public override string ToString() + { + return "JSONNode"; + } + + public virtual string ToString(string aIndent) + { + return ToString(aIndent, ""); + } + + internal abstract string ToString(string aIndent, string aPrefix); + + #endregion common interface + + #region typecasting properties + + public abstract JSONNodeType Tag { get; } + + public virtual double AsDouble + { + get + { + double v = 0.0; + if (double.TryParse(Value, out v)) + return v; + return 0.0; + } + set + { + Value = value.ToString(); + } + } + + public virtual int AsInt + { + get { return (int)AsDouble; } + set { AsDouble = value; } + } + + public virtual float AsFloat + { + get { return (float)AsDouble; } + set { AsDouble = value; } + } + + public virtual bool AsBool + { + get + { + bool v = false; + if (bool.TryParse(Value, out v)) + return v; + return !string.IsNullOrEmpty(Value); + } + set + { + Value = (value) ? "true" : "false"; + } + } + + public virtual JSONArray AsArray + { + get + { + return this as JSONArray; + } + } + + public virtual JSONObject AsObject + { + get + { + return this as JSONObject; + } + } + + + #endregion typecasting properties + + #region operators + + public static implicit operator JSONNode(string s) + { + return new JSONString(s); + } + public static implicit operator string(JSONNode d) + { + return (d == null) ? null : d.Value; + } + + public static implicit operator JSONNode(double n) + { + return new JSONNumber(n); + } + public static implicit operator double(JSONNode d) + { + return (d == null) ? 0 : d.AsDouble; + } + + public static implicit operator JSONNode(float n) + { + return new JSONNumber(n); + } + public static implicit operator float(JSONNode d) + { + return (d == null) ? 0 : d.AsFloat; + } + + public static implicit operator JSONNode(int n) + { + return new JSONNumber(n); + } + public static implicit operator int(JSONNode d) + { + return (d == null) ? 0 : d.AsInt; + } + + public static implicit operator JSONNode(bool b) + { + return new JSONBool(b); + } + public static implicit operator bool(JSONNode d) + { + return (d == null) ? false : d.AsBool; + } + + public static bool operator ==(JSONNode a, object b) + { + if (ReferenceEquals(a, b)) + return true; + bool aIsNull = a is JSONNull || ReferenceEquals(a, null) || a is JSONLazyCreator; + bool bIsNull = b is JSONNull || ReferenceEquals(b, null) || b is JSONLazyCreator; + return (aIsNull && bIsNull); + } + + public static bool operator !=(JSONNode a, object b) + { + return !(a == b); + } + + public override bool Equals(object obj) + { + return System.Object.ReferenceEquals(this, obj); + } + + public override int GetHashCode() + { + return base.GetHashCode(); + } + + #endregion operators + internal static StringBuilder m_EscapeBuilder = new StringBuilder(); + internal static string Escape(string aText) + { + m_EscapeBuilder.Length = 0; + if (m_EscapeBuilder.Capacity < aText.Length + aText.Length / 10) + m_EscapeBuilder.Capacity = aText.Length + aText.Length / 10; + foreach (char c in aText) + { + switch (c) + { + case '\\': + m_EscapeBuilder.Append("\\\\"); + break; + case '\"': + m_EscapeBuilder.Append("\""); + break; + case '\n': + m_EscapeBuilder.Append("\\n"); + break; + case '\r': + m_EscapeBuilder.Append("\\r"); + break; + case '\t': + m_EscapeBuilder.Append("\\t"); + break; + case '\b': + m_EscapeBuilder.Append("\\b"); + break; + case '\f': + m_EscapeBuilder.Append("\\f"); + break; + default: + m_EscapeBuilder.Append(c); + break; + } + } + string result = m_EscapeBuilder.ToString(); + m_EscapeBuilder.Length = 0; + return result; + } + + static void ParseElement(JSONNode ctx, string token, string tokenName, bool quoted) + { + if (quoted) + { + ctx.Add(tokenName, token); + return; + } + string tmp = token.ToLower(); + if (tmp == "false" || tmp == "true") + ctx.Add(tokenName, tmp == "true"); + else if (tmp == "null") + ctx.Add(tokenName, null); + else + { + double val; + if (double.TryParse(token, out val)) + ctx.Add(tokenName, val); + else + ctx.Add(tokenName, token); + } + } + + public static JSONNode Parse(string aJSON) + { + Stack stack = new Stack(); + JSONNode ctx = null; + int i = 0; + StringBuilder Token = new StringBuilder(); + string TokenName = ""; + bool QuoteMode = false; + bool TokenIsQuoted = false; + while (i < aJSON.Length) + { + switch (aJSON[i]) + { + case '{': + if (QuoteMode) + { + Token.Append(aJSON[i]); + break; + } + stack.Push(new JSONObject()); + if (ctx != null) + { + ctx.Add(TokenName, stack.Peek()); + } + TokenName = ""; + Token.Length = 0; + ctx = stack.Peek(); + break; + + case '[': + if (QuoteMode) + { + Token.Append(aJSON[i]); + break; + } + + stack.Push(new JSONArray()); + if (ctx != null) + { + ctx.Add(TokenName, stack.Peek()); + } + TokenName = ""; + Token.Length = 0; + ctx = stack.Peek(); + break; + + case '}': + case ']': + if (QuoteMode) + { + + Token.Append(aJSON[i]); + break; + } + if (stack.Count == 0) + throw new Exception("JSON Parse: Too many closing brackets"); + + stack.Pop(); + if (Token.Length > 0) + { + ParseElement(ctx, Token.ToString(), TokenName, TokenIsQuoted); + TokenIsQuoted = false; + } + TokenName = ""; + Token.Length = 0; + if (stack.Count > 0) + ctx = stack.Peek(); + break; + + case ':': + if (QuoteMode) + { + Token.Append(aJSON[i]); + break; + } + TokenName = Token.ToString().Trim(); + Token.Length = 0; + TokenIsQuoted = false; + break; + + case '"': + QuoteMode ^= true; + TokenIsQuoted |= QuoteMode; + break; + + case ',': + if (QuoteMode) + { + Token.Append(aJSON[i]); + break; + } + if (Token.Length > 0) + { + ParseElement(ctx, Token.ToString(), TokenName, TokenIsQuoted); + TokenIsQuoted = false; + } + TokenName = ""; + Token.Length = 0; + TokenIsQuoted = false; + break; + + case '\r': + case '\n': + break; + + case ' ': + case '\t': + if (QuoteMode) + Token.Append(aJSON[i]); + break; + + case '\\': + ++i; + if (QuoteMode) + { + char C = aJSON[i]; + switch (C) + { + case 't': + Token.Append('\t'); + break; + case 'r': + Token.Append('\r'); + break; + case 'n': + Token.Append('\n'); + break; + case 'b': + Token.Append('\b'); + break; + case 'f': + Token.Append('\f'); + break; + case 'u': + { + string s = aJSON.Substring(i + 1, 4); + Token.Append((char)int.Parse( + s, + System.Globalization.NumberStyles.AllowHexSpecifier)); + i += 4; + break; + } + default: + Token.Append(C); + break; + } + } + break; + + default: + Token.Append(aJSON[i]); + break; + } + ++i; + } + if (QuoteMode) + { + throw new Exception("JSON Parse: Quotation marks seems to be messed up."); + } + return ctx; + } + + public virtual void Serialize(System.IO.BinaryWriter aWriter) + { + } + + public void SaveToStream(System.IO.Stream aData) + { + var W = new System.IO.BinaryWriter(aData); + Serialize(W); + } + + #if USE_SharpZipLib + public void SaveToCompressedStream(System.IO.Stream aData) + { + using (var gzipOut = new ICSharpCode.SharpZipLib.BZip2.BZip2OutputStream(aData)) + { + gzipOut.IsStreamOwner = false; + SaveToStream(gzipOut); + gzipOut.Close(); + } + } + + public void SaveToCompressedFile(string aFileName) + { + + #if USE_FileIO + System.IO.Directory.CreateDirectory((new System.IO.FileInfo(aFileName)).Directory.FullName); + using(var F = System.IO.File.OpenWrite(aFileName)) + { + SaveToCompressedStream(F); + } + + #else + throw new Exception("Can't use File IO stuff in the webplayer"); + #endif + } + public string SaveToCompressedBase64() + { + using (var stream = new System.IO.MemoryStream()) + { + SaveToCompressedStream(stream); + stream.Position = 0; + return System.Convert.ToBase64String(stream.ToArray()); + } + } + + #else + public void SaveToCompressedStream(System.IO.Stream aData) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + + public void SaveToCompressedFile(string aFileName) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + + public string SaveToCompressedBase64() + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + #endif + + public void SaveToFile(string aFileName) + { + #if USE_FileIO + System.IO.Directory.CreateDirectory((new System.IO.FileInfo(aFileName)).Directory.FullName); + using (var F = System.IO.File.OpenWrite(aFileName)) + { + SaveToStream(F); + } + #else + throw new Exception ("Can't use File IO stuff in the webplayer"); + #endif + } + + public string SaveToBase64() + { + using (var stream = new System.IO.MemoryStream()) + { + SaveToStream(stream); + stream.Position = 0; + return System.Convert.ToBase64String(stream.ToArray()); + } + } + + public static JSONNode Deserialize(System.IO.BinaryReader aReader) + { + JSONNodeType type = (JSONNodeType)aReader.ReadByte(); + switch (type) + { + case JSONNodeType.Array: + { + int count = aReader.ReadInt32(); + JSONArray tmp = new JSONArray(); + for (int i = 0; i < count; i++) + tmp.Add(Deserialize(aReader)); + return tmp; + } + case JSONNodeType.Object: + { + int count = aReader.ReadInt32(); + JSONObject tmp = new JSONObject(); + for (int i = 0; i < count; i++) + { + string key = aReader.ReadString(); + var val = Deserialize(aReader); + tmp.Add(key, val); + } + return tmp; + } + case JSONNodeType.String: + { + return new JSONString(aReader.ReadString()); + } + case JSONNodeType.Number: + { + return new JSONNumber(aReader.ReadDouble()); + } + case JSONNodeType.Boolean: + { + return new JSONBool(aReader.ReadBoolean()); + } + case JSONNodeType.NullValue: + { + return new JSONNull(); + } + default: + { + throw new Exception("Error deserializing JSON. Unknown tag: " + type); + } + } + } + + #if USE_SharpZipLib + public static JSONNode LoadFromCompressedStream(System.IO.Stream aData) + { + var zin = new ICSharpCode.SharpZipLib.BZip2.BZip2InputStream(aData); + return LoadFromStream(zin); + } + public static JSONNode LoadFromCompressedFile(string aFileName) + { + #if USE_FileIO + using(var F = System.IO.File.OpenRead(aFileName)) + { + return LoadFromCompressedStream(F); + } + #else + throw new Exception("Can't use File IO stuff in the webplayer"); + #endif + } + public static JSONNode LoadFromCompressedBase64(string aBase64) + { + var tmp = System.Convert.FromBase64String(aBase64); + var stream = new System.IO.MemoryStream(tmp); + stream.Position = 0; + return LoadFromCompressedStream(stream); + } + #else + public static JSONNode LoadFromCompressedFile(string aFileName) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + + public static JSONNode LoadFromCompressedStream(System.IO.Stream aData) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + + public static JSONNode LoadFromCompressedBase64(string aBase64) + { + throw new Exception("Can't use compressed functions. You need include the SharpZipLib and uncomment the define at the top of SimpleJSON"); + } + #endif + + public static JSONNode LoadFromStream(System.IO.Stream aData) + { + using (var R = new System.IO.BinaryReader(aData)) + { + return Deserialize(R); + } + } + + public static JSONNode LoadFromFile(string aFileName) + { + #if USE_FileIO + using (var F = System.IO.File.OpenRead(aFileName)) + { + return LoadFromStream(F); + } + #else + throw new Exception ("Can't use File IO stuff in the webplayer"); + #endif + } + + public static JSONNode LoadFromBase64(string aBase64) + { + var tmp = System.Convert.FromBase64String(aBase64); + var stream = new System.IO.MemoryStream(tmp); + stream.Position = 0; + return LoadFromStream(stream); + } + } + // End of JSONNode + + public class JSONArray : JSONNode, IEnumerable + { + private List m_List = new List(); + + public override JSONNodeType Tag { get { return JSONNodeType.Array; } } + public override bool IsArray { get { return true; } } + + + + public override JSONNode this[int aIndex] + { + get + { + if (aIndex < 0 || aIndex >= m_List.Count) + return new JSONLazyCreator(this); + return m_List[aIndex]; + } + set + { + if (value == null) + value = new JSONNull(); + if (aIndex < 0 || aIndex >= m_List.Count) + m_List.Add(value); + else + m_List[aIndex] = value; + } + } + + public override JSONNode this[string aKey] + { + get { return new JSONLazyCreator(this); } + set + { + if (value == null) + value = new JSONNull(); + m_List.Add(value); + } + } + + public override int Count + { + get { return m_List.Count; } + } + + public override void Add(string aKey, JSONNode aItem) + { + if (aItem == null) + aItem = new JSONNull(); + m_List.Add(aItem); + } + + public override JSONNode Remove(int aIndex) + { + if (aIndex < 0 || aIndex >= m_List.Count) + return null; + JSONNode tmp = m_List[aIndex]; + m_List.RemoveAt(aIndex); + return tmp; + } + + public override JSONNode Remove(JSONNode aNode) + { + m_List.Remove(aNode); + return aNode; + } + + public override IEnumerable Children + { + get + { + foreach (JSONNode N in m_List) + yield return N; + } + } + + public IEnumerator GetEnumerator() + { + foreach (JSONNode N in m_List) + yield return N; + } + + public override string ToString() + { + string result = "[ "; + foreach (JSONNode N in m_List) + { + if (result.Length > 2) + result += ", "; + result += N.ToString(); + } + result += " ]"; + return result; + } + + internal override string ToString(string aIndent, string aPrefix) + { + string result = "[ "; + foreach (JSONNode N in m_List) + { + if (result.Length > 3) + result += ", "; + result += "\n"+aPrefix + aIndent + N.ToString(aIndent, aPrefix + aIndent); + } + result += "\n" + aPrefix + "]"; + return result; + } + + public override void Serialize(System.IO.BinaryWriter aWriter) + { + aWriter.Write((byte)JSONNodeType.Array); + aWriter.Write(m_List.Count); + for (int i = 0; i < m_List.Count; i++) + { + m_List[i].Serialize(aWriter); + } + } + } + // End of JSONArray + + public class JSONObject : JSONNode, IEnumerable + { + private Dictionary m_Dict = new Dictionary(); + + public override JSONNodeType Tag { get { return JSONNodeType.Object; } } + public override bool IsObject { get { return true; } } + + + public override JSONNode this[string aKey] + { + get + { + if (m_Dict.ContainsKey(aKey)) + return m_Dict[aKey]; + else + return new JSONLazyCreator(this, aKey); + } + set + { + if (value == null) + value = new JSONNull(); + if (m_Dict.ContainsKey(aKey)) + m_Dict[aKey] = value; + else + m_Dict.Add(aKey, value); + } + } + + public override JSONNode this[int aIndex] + { + get + { + if (aIndex < 0 || aIndex >= m_Dict.Count) + return null; + return m_Dict.ElementAt(aIndex).Value; + } + set + { + if (value == null) + value = new JSONNull(); + if (aIndex < 0 || aIndex >= m_Dict.Count) + return; + string key = m_Dict.ElementAt(aIndex).Key; + m_Dict[key] = value; + } + } + + public override int Count + { + get { return m_Dict.Count; } + } + + public override void Add(string aKey, JSONNode aItem) + { + if (aItem == null) + aItem = new JSONNull(); + + if (!string.IsNullOrEmpty(aKey)) + { + if (m_Dict.ContainsKey(aKey)) + m_Dict[aKey] = aItem; + else + m_Dict.Add(aKey, aItem); + } + else + m_Dict.Add(Guid.NewGuid().ToString(), aItem); + } + + public override JSONNode Remove(string aKey) + { + if (!m_Dict.ContainsKey(aKey)) + return null; + JSONNode tmp = m_Dict[aKey]; + m_Dict.Remove(aKey); + return tmp; + } + + public override JSONNode Remove(int aIndex) + { + if (aIndex < 0 || aIndex >= m_Dict.Count) + return null; + var item = m_Dict.ElementAt(aIndex); + m_Dict.Remove(item.Key); + return item.Value; + } + + public override JSONNode Remove(JSONNode aNode) + { + try + { + var item = m_Dict.Where(k => k.Value == aNode).First(); + m_Dict.Remove(item.Key); + return aNode; + } + catch + { + return null; + } + } + + public override IEnumerable Children + { + get + { + foreach (KeyValuePair N in m_Dict) + yield return N.Value; + } + } + + public IEnumerator GetEnumerator() + { + foreach (KeyValuePair N in m_Dict) + yield return N; + } + + public override string ToString() + { + string result = "{"; + foreach (KeyValuePair N in m_Dict) + { + if (result.Length > 2) + result += ", "; + result += "\"" + Escape(N.Key) + "\":" + N.Value.ToString(); + } + result += "}"; + return result; + } + + internal override string ToString(string aIndent, string aPrefix) + { + string result = "{ "; + foreach (KeyValuePair N in m_Dict) + { + if (result.Length > 3) + result += ", "; + result += "\n" + aPrefix + aIndent + "\"" + Escape(N.Key) + "\" : "; + result += N.Value.ToString(aIndent, aPrefix + aIndent); + } + result += "\n" + aPrefix + "}"; + return result; + } + + public override void Serialize(System.IO.BinaryWriter aWriter) + { + aWriter.Write((byte)JSONNodeType.Object); + aWriter.Write(m_Dict.Count); + foreach (string K in m_Dict.Keys) + { + aWriter.Write(K); + m_Dict[K].Serialize(aWriter); + } + } + } + // End of JSONObject + + public class JSONString : JSONNode + { + private string m_Data; + + public override JSONNodeType Tag { get { return JSONNodeType.String; } } + public override bool IsString { get { return true; } } + + public override string Value + { + get { return m_Data; } + set + { + m_Data = value; + } + } + + public JSONString(string aData) + { + m_Data = aData; + } + + public override string ToString() + { + return "\"" + Escape(m_Data) + "\""; + } + + internal override string ToString(string aIndent, string aPrefix) + { + return "\"" + Escape(m_Data) + "\""; + } + + public override void Serialize(System.IO.BinaryWriter aWriter) + { + aWriter.Write((byte)JSONNodeType.String); + aWriter.Write(m_Data); + } + } + // End of JSONString + + + public class JSONNumber : JSONNode + { + private double m_Data; + + public override JSONNodeType Tag { get { return JSONNodeType.Number; } } + public override bool IsNumber { get { return true; } } + + + public override string Value + { + get { return m_Data.ToString(); } + set + { + double v; + if (double.TryParse(value, out v)) + m_Data = v; + } + } + + public override double AsDouble + { + get { return m_Data; } + set { m_Data = value; } + } + + public JSONNumber(double aData) + { + m_Data = aData; + } + + public JSONNumber(string aData) + { + Value = aData; + } + + public override string ToString() + { + return m_Data.ToString(); + } + + internal override string ToString(string aIndent, string aPrefix) + { + return m_Data.ToString(); + } + + public override void Serialize(System.IO.BinaryWriter aWriter) + { + aWriter.Write((byte)JSONNodeType.Number); + aWriter.Write(m_Data); + } + } + // End of JSONNumber + + + public class JSONBool : JSONNode + { + private bool m_Data; + + public override JSONNodeType Tag { get { return JSONNodeType.Boolean; } } + public override bool IsBoolean { get { return true; } } + + + public override string Value + { + get { return m_Data.ToString(); } + set + { + bool v; + if (bool.TryParse(value, out v)) + m_Data = v; + } + } + public override bool AsBool + { + get { return m_Data; } + set { m_Data = value; } + } + + public JSONBool(bool aData) + { + m_Data = aData; + } + + public JSONBool(string aData) + { + Value = aData; + } + + public override string ToString() + { + return (m_Data) ? "true" : "false"; + } + + internal override string ToString(string aIndent, string aPrefix) + { + return (m_Data) ? "true" : "false"; + } + + public override void Serialize(System.IO.BinaryWriter aWriter) + { + aWriter.Write((byte)JSONNodeType.Boolean); + aWriter.Write(m_Data); + } + } + // End of JSONBool + + + public class JSONNull : JSONNode + { + + public override JSONNodeType Tag { get { return JSONNodeType.NullValue; } } + public override bool IsNull { get { return true; } } + + + public override string Value + { + get { return "null"; } + set { } + } + public override bool AsBool + { + get { return false; } + set { } + } + + public override string ToString() + { + return "null"; + } + + internal override string ToString(string aIndent, string aPrefix) + { + return "null"; + } + + public override bool Equals(object obj) + { + if (object.ReferenceEquals(this, obj)) + return true; + return (obj is JSONNull); + } + public override int GetHashCode() + { + return base.GetHashCode(); + } + + public override void Serialize(System.IO.BinaryWriter aWriter) + { + aWriter.Write((byte)JSONNodeType.NullValue); + } + } + // End of JSONNull + + internal class JSONLazyCreator : JSONNode + { + private JSONNode m_Node = null; + private string m_Key = null; + + public override JSONNodeType Tag { get { return JSONNodeType.None; } } + + public JSONLazyCreator(JSONNode aNode) + { + m_Node = aNode; + m_Key = null; + } + + public JSONLazyCreator(JSONNode aNode, string aKey) + { + m_Node = aNode; + m_Key = aKey; + } + + private void Set(JSONNode aVal) + { + if (m_Key == null) + { + m_Node.Add(aVal); + } + else + { + m_Node.Add(m_Key, aVal); + } + m_Node = null; // Be GC friendly. + } + + public override JSONNode this[int aIndex] + { + get + { + return new JSONLazyCreator(this); + } + set + { + var tmp = new JSONArray(); + tmp.Add(value); + Set(tmp); + } + } + + public override JSONNode this[string aKey] + { + get + { + return new JSONLazyCreator(this, aKey); + } + set + { + var tmp = new JSONObject(); + tmp.Add(aKey, value); + Set(tmp); + } + } + + public override void Add(JSONNode aItem) + { + var tmp = new JSONArray(); + tmp.Add(aItem); + Set(tmp); + } + + public override void Add(string aKey, JSONNode aItem) + { + var tmp = new JSONObject(); + tmp.Add(aKey, aItem); + Set(tmp); + } + + public static bool operator ==(JSONLazyCreator a, object b) + { + if (b == null) + return true; + return System.Object.ReferenceEquals(a, b); + } + + public static bool operator !=(JSONLazyCreator a, object b) + { + return !(a == b); + } + + public override bool Equals(object obj) + { + if (obj == null) + return true; + return System.Object.ReferenceEquals(this, obj); + } + + public override int GetHashCode() + { + return base.GetHashCode(); + } + + public override string ToString() + { + return ""; + } + + internal override string ToString(string aIndent, string aPrefix) + { + return ""; + } + + public override int AsInt + { + get + { + JSONNumber tmp = new JSONNumber(0); + Set(tmp); + return 0; + } + set + { + JSONNumber tmp = new JSONNumber(value); + Set(tmp); + } + } + + public override float AsFloat + { + get + { + JSONNumber tmp = new JSONNumber(0.0f); + Set(tmp); + return 0.0f; + } + set + { + JSONNumber tmp = new JSONNumber(value); + Set(tmp); + } + } + + public override double AsDouble + { + get + { + JSONNumber tmp = new JSONNumber(0.0); + Set(tmp); + return 0.0; + } + set + { + JSONNumber tmp = new JSONNumber(value); + Set(tmp); + } + } + + public override bool AsBool + { + get + { + JSONBool tmp = new JSONBool(false); + Set(tmp); + return false; + } + set + { + JSONBool tmp = new JSONBool(value); + Set(tmp); + } + } + + public override JSONArray AsArray + { + get + { + JSONArray tmp = new JSONArray(); + Set(tmp); + return tmp; + } + } + + public override JSONObject AsObject + { + get + { + JSONObject tmp = new JSONObject(); + Set(tmp); + return tmp; + } + } + } + // End of JSONLazyCreator + + public static class JSON + { + public static JSONNode Parse(string aJSON) + { + return JSONNode.Parse(aJSON); + } + } +} \ No newline at end of file diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/SimpleJSON.cs.meta b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/SimpleJSON.cs.meta new file mode 100644 index 00000000..402c8d77 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/SimpleJSON.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: d16e468630fe048df98d8f3c36553c28 +timeCreated: 1490262127 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/UmengAndroidLifeCycleCallBack.cs b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/UmengAndroidLifeCycleCallBack.cs new file mode 100644 index 00000000..861a79f3 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/UmengAndroidLifeCycleCallBack.cs @@ -0,0 +1,55 @@ +// +// UmengManager.cs +// +// Created by ZhuCong on 1/1/14. +// Copyright 2014 Umeng.com . All rights reserved. +// Version 1.31 +// 请不要改动此类的内容,也不要手动添加此类到gameObject上.Umeng SDK会自动实例化此类 + +using UnityEngine; +using System.Collections; +using Umeng; + +public class UmengAndroidLifeCycleCallBack : MonoBehaviour +{ + #if UNITY_ANDROID + + void Awake() + { + DontDestroyOnLoad (transform.gameObject); + } + + + + void OnApplicationPause(bool isPause) + { + + //Debug.Log("Umeng:OnApplicationPause" + isPause); + if (isPause){ + //Debug.Log("Umeng:----onPause"); + GA.onPause(); + } + else{ + //Debug.Log("Umeng:----onResume"); + GA.onResume(); + } + + } + + + + void OnApplicationQuit() + { + //Debug.Log("Umeng:OnApplicationQuit"); + GA.onKillProcess(); + } + + + + #endif + + + + + +} diff --git a/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/UmengAndroidLifeCycleCallBack.cs.meta b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/UmengAndroidLifeCycleCallBack.cs.meta new file mode 100644 index 00000000..e99f9f45 --- /dev/null +++ b/popcorn/Assets/JoyPacSDK/Umeng/UmengGameAnalytics/Scripts/UmengAndroidLifeCycleCallBack.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 04b427f78c0ea44239dfb7e9597d365a +timeCreated: 1533700738 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac.meta b/popcorn/Assets/Joypac.meta new file mode 100644 index 00000000..ff1b1ce7 --- /dev/null +++ b/popcorn/Assets/Joypac.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b6a55383eb3d84eecbfbfbe63b2bfbb2 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Editor.meta b/popcorn/Assets/Joypac/Editor.meta new file mode 100644 index 00000000..e14899a0 --- /dev/null +++ b/popcorn/Assets/Joypac/Editor.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ed0080b29840a4382be9897569d540a3 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Editor/JoypacI2AttPostBuild.cs b/popcorn/Assets/Joypac/Editor/JoypacI2AttPostBuild.cs new file mode 100644 index 00000000..1b2b32d4 --- /dev/null +++ b/popcorn/Assets/Joypac/Editor/JoypacI2AttPostBuild.cs @@ -0,0 +1,88 @@ +/*create by :闫婷婷 + * date :2021/6/23 + */ +#if UNITY_IOS || UNITY_IPHONE +using UnityEditor.Callbacks; +using System.Collections; +using I2.Loc; +using System.Collections.Generic; +using UnityEditor.iOS_I2Loc.Xcode; +using System.IO; +using UnityEditor; +using UnityEngine; +using System.Linq; + +using System; +/// +/// Joypac i2 ATT post build. +/// +public class JoypacI2AttPostBuild +{ + [PostProcessBuild(20000)] + public static void ChangeXcodePlist(BuildTarget buildTarget, string pathToBuiltProject) + { + if (buildTarget != BuildTarget.iOS) + return; + if (LocalizationManager.Sources.Count <= 0) + LocalizationManager.UpdateSources(); + var langCodes = LocalizationManager.GetAllLanguagesCode(false).Concat(LocalizationManager.GetAllLanguagesCode(true)).Distinct().ToList(); + if (langCodes.Count <= 0) + return; + try + { + + //--[ Localize App Name ]---------- + + string LocalizationRoot = pathToBuiltProject + "/I2Localization"; + if (!Directory.Exists(LocalizationRoot)) + Directory.CreateDirectory(LocalizationRoot); + var project = new PBXProject(); + string projPath = PBXProject.GetPBXProjectPath(pathToBuiltProject); + //if (!projPath.EndsWith("xcodeproj")) + //projPath = projPath.Substring(0, projPath.LastIndexOfAny("/\\".ToCharArray())); + + project.ReadFromFile(projPath); + //var targetName = PBXProject.GetUnityTargetName(); + //string projBuild = project.TargetGuidByName( targetName ); + + //project.RemoveLocalizationVariantGroup("I2 Localization"); + + // Set the Language Overrides + foreach (var code in langCodes) + { + if (code == null || code.Length < 2) + continue; + string[] all = new string[2]; + var LanguageDirRoot = LocalizationRoot + "/" + code + ".lproj"; + if (!Directory.Exists(LanguageDirRoot)) + Directory.CreateDirectory(LanguageDirRoot); + + var infoPlistPath = LanguageDirRoot + "/InfoPlist.strings"; + all[0] = File.ReadAllText(infoPlistPath); + string Att = "Your data will only be used to deliver personalized ads to you."; + if (code.Contains("zh")) + { + Att = "您的数据将用于向您投放个性化广告。"; + } + all[1] = string.Format("\"NSUserTrackingUsageDescription\" = \"{0}\";", Att); + File.WriteAllLines(infoPlistPath, all); + var langProjectRoot = "I2Localization/" + code + ".lproj"; + if(project.FindFileGuidByProjectPath("I2 Localization"+"/"+ langProjectRoot + "/InfoPlist.strings") == String.Empty) + { + Debug.Log("Empty!! add InfoPlist.strings"); + project.AddLocalization(langProjectRoot + "/InfoPlist.strings", langProjectRoot + "/InfoPlist.strings", "I2 Localization"); + } + else + { + + } + } + project.WriteToFile(projPath); + } + catch (System.Exception e) + { + Debug.Log(e); + } + } +} +#endif \ No newline at end of file diff --git a/popcorn/Assets/Joypac/Editor/JoypacI2AttPostBuild.cs.meta b/popcorn/Assets/Joypac/Editor/JoypacI2AttPostBuild.cs.meta new file mode 100644 index 00000000..3c07a4c0 --- /dev/null +++ b/popcorn/Assets/Joypac/Editor/JoypacI2AttPostBuild.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: d5bf69213c4ba4fb1a8bc661ec22fe81 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins.meta b/popcorn/Assets/Joypac/Plugins.meta new file mode 100644 index 00000000..558e261a --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cf2ed9a82e99f468c94cf2015451bfbe +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/Android.meta b/popcorn/Assets/Joypac/Plugins/Android.meta new file mode 100644 index 00000000..4f505aed --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/Android.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1ff684d316f5145269c051d65faad12b +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/Android/libs.meta b/popcorn/Assets/Joypac/Plugins/Android/libs.meta new file mode 100644 index 00000000..189f01eb --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/Android/libs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8170ba653303d43ff9fd1c605329e631 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/Android/libs/unityUmengBridge.jar b/popcorn/Assets/Joypac/Plugins/Android/libs/unityUmengBridge.jar new file mode 100644 index 00000000..8ad930c8 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/Android/libs/unityUmengBridge.jar differ diff --git a/popcorn/Assets/Joypac/Plugins/Android/libs/unityUmengBridge.jar.meta b/popcorn/Assets/Joypac/Plugins/Android/libs/unityUmengBridge.jar.meta new file mode 100644 index 00000000..dbe293ad --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/Android/libs/unityUmengBridge.jar.meta @@ -0,0 +1,32 @@ +fileFormatVersion: 2 +guid: fdaf93f24088144d783a954f96a9c5ec +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Android: Android + second: + enabled: 1 + settings: {} + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/Android/libs/unitybridge.jar b/popcorn/Assets/Joypac/Plugins/Android/libs/unitybridge.jar new file mode 100644 index 00000000..ac849d9c Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/Android/libs/unitybridge.jar differ diff --git a/popcorn/Assets/Joypac/Plugins/Android/libs/unitybridge.jar.meta b/popcorn/Assets/Joypac/Plugins/Android/libs/unitybridge.jar.meta new file mode 100644 index 00000000..8bbe70f4 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/Android/libs/unitybridge.jar.meta @@ -0,0 +1,32 @@ +fileFormatVersion: 2 +guid: 8d995c7efa8034476ba3b94f5040f263 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Android: Android + second: + enabled: 1 + settings: {} + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet.meta new file mode 100644 index 00000000..dbb8260f --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b5677858eb82644589967e7980db1dd5 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies.meta new file mode 100644 index 00000000..59ac16b1 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 577d9725f58264943855b8ac185531fe +folderAsset: yes +timeCreated: 1466788344 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone.meta new file mode 100644 index 00000000..242f110e --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 01ef782d02bb1994dbe418b69432552b +folderAsset: yes +timeCreated: 1466788344 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone/Newtonsoft.Json.XML b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone/Newtonsoft.Json.XML new file mode 100644 index 00000000..4dbcd9ea --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone/Newtonsoft.Json.XML @@ -0,0 +1,8040 @@ + + + + Newtonsoft.Json + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized JSON data. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a JSON array. + + + + + Writes the beginning of a JSON object. + + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Represents a BSON Oid (object id). + + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Initializes a new instance of the class. + + The Oid value. + + + + Converts a binary value to and from a base 64 string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + + + + + + + + + + + + + + + + + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Gets or sets a value indicating whether integer values are allowed. + + true if integers are allowed; otherwise, false. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + true if the written enum text will be camel case; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Json Converter for Vector2, Vector3 and Vector4. Only serializes x, y, (z) and (w) properties. + + + + + Default Constructor - All Vector types enabled by default + + + + + Selectively enable Vector types + + Use for Vector2 objects + Use for Vector3 objects + Use for Vector4 objects + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts XML to and from JSON. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produces multiple root elements. + + The name of the deserialize root element. + + + + Gets or sets a flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attibute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the attributeName is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + True if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Specifies float format handling options when writing special floating point numbers, e.g. , + and with . + + + + + Write special floating point values as strings in JSON, e.g. "NaN", "Infinity", "-Infinity". + + + + + Write special floating point values as symbols in JSON, e.g. NaN, Infinity, -Infinity. + Note that this will produce non-valid JSON. + + + + + Write special floating point values as the property's default value in JSON, e.g. 0.0 for a property, null for a property. + + + + + Specifies how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Floating point numbers are parsed to . + + + + + Floating point numbers are parsed to . + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Provides an interface for using pooled arrays. + + The array type content. + + + + Rent a array from the pool. This array must be returned when it is no longer needed. + + The minimum required length of the array. The returned array may be longer. + The rented array from the pool. This array must be returned when it is no longer needed. + + + + Return an array to the pool. + + The array that is being returned. + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during JSON serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Instructs the to deserialize properties with no matching class member into the specified collection + and write values during serialization. + + + + + Gets or sets a value that indicates whether to write extension data when serializing the object. + + + true to write extension data when serializing the object; otherwise, false. The default is true. + + + + + Gets or sets a value that indicates whether to read extension data when deserializing the object. + + + true to read extension data when deserializing the object; otherwise, false. The default is true. + + + + + Initializes a new instance of the class. + + + + + Instructs the to always serialize the member, and require the member has a value. + + + + + Specifies how JSON comments are handled when loading JSON. + + + + + Ignore comments. + + + + + Load comments as a with type . + + + + + Specifies how line information is handled when loading JSON. + + + + + Ignore line information. + + + + + Load line information. + + + + + Represents a view of a . + + + + + Initializes a new instance of the class. + + The name. + + + + When overridden in a derived class, returns whether resetting an object changes its value. + + + true if resetting the component changes its value; otherwise, false. + + The component to test for reset capability. + + + + + When overridden in a derived class, gets the current value of the property on a component. + + + The value of a property for a given component. + + The component with the property for which to retrieve the value. + + + + + When overridden in a derived class, resets the value for this property of the component to the default value. + + The component with the property value that is to be reset to the default value. + + + + + When overridden in a derived class, sets the value of the component to a different value. + + The component with the property value that is to be set. + The new value. + + + + + When overridden in a derived class, determines a value indicating whether the value of this property needs to be persisted. + + + true if the property should be persisted; otherwise, false. + + The component with the property to be examined for persistence. + + + + + When overridden in a derived class, gets the type of the component this property is bound to. + + + A that represents the type of component this property is bound to. When the or methods are invoked, the object specified might be an instance of this type. + + + + + When overridden in a derived class, gets a value indicating whether this property is read-only. + + + true if the property is read-only; otherwise, false. + + + + + When overridden in a derived class, gets the type of the property. + + + A that represents the type of the property. + + + + + Gets the hash code for the name of the member. + + + + The hash code for the name of the member. + + + + + Specifies the settings used when loading JSON. + + + + + Gets or sets how JSON comments are handled when loading JSON. + + The JSON comment handling. + + + + Gets or sets how JSON line info is handled when loading JSON. + + The JSON line info handling. + + + + Specifies the settings used when merging JSON. + + + + + Gets or sets the method used when merging JSON arrays. + + The method used when merging JSON arrays. + + + + Gets or sets how how null value properties are merged. + + How null value properties are merged. + + + + Specifies how JSON arrays are merged together. + + + + Concatenate arrays. + + + Union arrays, skipping items that already exist. + + + Replace all array items. + + + Merge array items together, matched by index. + + + + Specifies how null value properties are merged. + + + + + The content's null value properties will be ignored during merging. + + + + + The content's null value properties will be merged. + + + + + Represents a raw JSON string. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every token in the source collection. + + + + Returns a collection of tokens that contains every token in the source collection, and the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains every token in the source collection, the ancestors of every token in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every token in the source collection. + + + + Returns a collection of tokens that contains every token in the source collection, and the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains every token in the source collection, and the descendants of every token in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every token in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every token in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every token in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every token in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every token in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every token in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a JSON constructor. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Represents a token that can contain other tokens. + + + + + Occurs when the list changes or an item in the list changes. + + + + + Occurs before an item is added to the collection. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Raises the event. + + The instance containing the event data. + + + + Raises the event. + + The instance containing the event data. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Returns a collection of the tokens that contain this token, and all descendant tokens of this token, in document order. + + An containing this token, and all the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Merge the specified content into this . + + The content to be merged. + + + + Merge the specified content into this using . + + The content to be merged. + The used to merge the content. + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Gets the with the specified key. + + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Represents a JSON object. + + + + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Occurs when a property value is changing. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets the node type for this . + + The type. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Returns the properties for this instance of a component. + + + A that represents the properties for this component instance. + + + + + Returns the properties for this instance of a component using the attribute array as a filter. + + An array of type that is used as a filter. + + A that represents the filtered properties for this component instance. + + + + + Returns a collection of custom attributes for this instance of a component. + + + An containing the attributes for this object. + + + + + Returns the class name of this instance of a component. + + + The class name of the object, or null if the class does not have a name. + + + + + Returns the name of this instance of a component. + + + The name of the object, or null if the object does not have a name. + + + + + Returns a type converter for this instance of a component. + + + A that is the converter for this object, or null if there is no for this object. + + + + + Returns the default event for this instance of a component. + + + An that represents the default event for this object, or null if this object does not have events. + + + + + Returns the default property for this instance of a component. + + + A that represents the default property for this object, or null if this object does not have properties. + + + + + Returns an editor of the specified type for this instance of a component. + + A that represents the editor for this object. + + An of the specified type that is the editor for this object, or null if the editor cannot be found. + + + + + Returns the events for this instance of a component using the specified attribute array as a filter. + + An array of type that is used as a filter. + + An that represents the filtered events for this component instance. + + + + + Returns the events for this instance of a component. + + + An that represents the events for this component instance. + + + + + Returns an object that contains the property described by the specified property descriptor. + + A that represents the property whose owner is to be found. + + An that represents the owner of the specified property. + + + + + Represents a JSON array. + + + + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Copies to. + + The array. + Index of the array. + + + + Gets a value indicating whether the is read-only. + + true if the is read-only; otherwise, false. + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized JSON data. + + + + + Gets the at the reader's current position. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Gets the path of the current JSON token. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets the at the writer's current position. + + + + + Gets the token being writen. + + The token being writen. + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Represents an abstract JSON token. + + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the path of the JSON token. + + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of tokens that contain this token, and the ancestors of this token. + + A collection of tokens that contain this token, and the ancestors of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to []. + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from [] to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Creates a from a . + + An positioned at the token to read into this . + The used to load the JSON. + If this is null, default load settings will be used. + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + The used to load the JSON. + If this is null, default load settings will be used. + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects a using a JPath expression. Selects the token that matches the object path. + + + A that contains a JPath expression. + + A , or null. + + + + Selects a using a JPath expression. Selects the token that matches the object path. + + + A that contains a JPath expression. + + A flag to indicate whether an error should be thrown if no tokens are found when evaluating part of the expression. + A . + + + + Selects a collection of elements using a JPath expression. + + + A that contains a JPath expression. + + An that contains the selected elements. + + + + Selects a collection of elements using a JPath expression. + + + A that contains a JPath expression. + + A flag to indicate whether an error should be thrown if no tokens are found when evaluating part of the expression. + An that contains the selected elements. + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Adds an object to the annotation list of this . + + The annotation to add. + + + + Get the first annotation object of the specified type from this . + + The type of the annotation to retrieve. + The first annotation object that matches the specified type, or null if no annotation is of the specified type. + + + + Gets the first annotation object of the specified type from this . + + The of the annotation to retrieve. + The first annotation object that matches the specified type, or null if no annotation is of the specified type. + + + + Gets a collection of annotations of the specified type for this . + + The type of the annotations to retrieve. + An that contains the annotations for this . + + + + Gets a collection of annotations of the specified type for this . + + The of the annotations to retrieve. + An of that contains the annotations that match the specified type for this . + + + + Removes the annotations of the specified type from this . + + The type of annotations to remove. + + + + Removes the annotations of the specified type from this . + + The of annotations to remove. + + + + Represents a JSON property. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Creates a null value. + + A null value. + + + + Creates a undefined value. + + A undefined value. + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Specifies metadata property handling options for the . + + + + + Read metadata properties located at the start of a JSON object. + + + + + Read metadata properties located anywhere in a JSON object. Note that this setting will impact performance. + + + + + Do not try to read metadata properties. + + + + + Represents a trace writer that writes to the application's instances. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Provides methods to get attributes. + + + + + Returns a collection of all of the attributes, or an empty collection if there are no attributes. + + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Returns a collection of attributes, identified by type, or an empty collection if there are no attributes. + + The type of the attributes. + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Represents a trace writer. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Contract details for a used by the . + + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Provides methods to get attributes from a , , or . + + + + + Initializes a new instance of the class. + + The instance to get attributes for. This parameter should be a , , or . + + + + Returns a collection of all of the attributes, or an empty collection if there are no attributes. + + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Returns a collection of attributes, identified by type, or an empty collection if there are no attributes. + + The type of the attributes. + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Contract details for a used by the . + + + + + Gets or sets the ISerializable object constructor. + + The ISerializable object constructor. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Get and set values for a using dynamic methods. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Provides data for the Error event. + + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Resolves member mappings for a type, camel casing property names. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + Used by to resolves a for a given . + + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the interface when serializing and deserializing types. + + + true if the interface will be ignored when serializing and deserializing types; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the attribute when serializing and deserializing types. + + + true if the attribute will be ignored when serializing and deserializing types; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly improve performance with multiple resolver instances because expensive reflection will only + happen once. This setting can cause unexpected behavior if different instances of the resolver are suppose to produce different + results. When set to false it is highly recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Resolved name of the property. + + + + Resolves the key of the dictionary. By default is used to resolve dictionary keys. + + Key of the dictionary. + Resolved key of the dictionary. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + Provides information surrounding an error. + + + + + Gets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Contract details for a used by the . + + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Gets or sets the function used to create the object. When set this function will override . + + The function used to create the object. + + + + Gets a value indicating whether the creator has a parameter with the collection values. + + true if the creator has a parameter with the collection values; otherwise, false. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Handles serialization callback events. + + The object that raised the callback event. + The streaming context. + + + + Handles serialization error callback events. + + The object that raised the callback event. + The streaming context. + The error context. + + + + Sets extension data for an object during deserialization. + + The object to set extension data on. + The extension data key. + The extension data value. + + + + Gets extension data for an object during serialization. + + The object to set extension data on. + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets all methods called immediately after deserialization of the object. + + The methods called immediately after deserialization of the object. + + + + Gets or sets all methods called during deserialization of the object. + + The methods called during deserialization of the object. + + + + Gets or sets all methods called after serialization of the object graph. + + The methods called after serialization of the object graph. + + + + Gets or sets all methods called before serialization of the object. + + The methods called before serialization of the object. + + + + Gets or sets all method called when an error is thrown during the serialization of the object. + + The methods called when an error is thrown during the serialization of the object. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Contract details for a used by the . + + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets or sets the dictionary key resolver. + + The dictionary key resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Gets or sets the function used to create the object. When set this function will override . + + The function used to create the object. + + + + Gets a value indicating whether the creator has a parameter with the dictionary values. + + true if the creator has a parameter with the dictionary values; otherwise, false. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization of a member. + + The numeric order of serialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the for this property. + + The for this property. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets or sets the member converter. + + The member converter. + + + + Gets or sets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets or sets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets or sets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets or sets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets or sets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets or sets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets or sets the property null value handling. + + The null value handling. + + + + Gets or sets the property default value handling. + + The default value handling. + + + + Gets or sets the property reference loop handling. + + The reference loop handling. + + + + Gets or sets the property object creation handling. + + The object creation handling. + + + + Gets or sets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be deserialized. + + A predicate used to determine whether the property should be deserialized. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + Contract details for a used by the . + + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets a collection of instances that define the parameters used with . + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Gets or sets the function used to create the object. When set this function will override . + This function is called with a collection of arguments which are defined by the collection. + + The function used to create the object. + + + + Gets or sets the extension data setter. + + + + + Gets or sets the extension data getter. + + + + + Gets or sets the extension data value type. + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Lookup and create an instance of the JsonConverter type described by the argument. + + The JsonConverter type to create. + Optional arguments to pass to an initializing constructor of the JsonConverter. + If null, the default constructor is used. + + + + Create a factory function that can be used to create instances of a JsonConverter described by the + argument type. The returned function can then be used to either invoke the converter's default ctor, or any + parameterized constructors by way of an object array. + + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Represents a method that constructs an object. + + The object type to create. + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + The property is not required but it cannot be a null value. + + + + + Specifies reference handling options for the . + Note that references cannot be preserved when a value is set via a non-default constructor such as types that implement ISerializable. + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Instructs the how to serialize the collection. + + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Instructs the how to serialize the object. + + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + The parameter list to use when constructing the JsonConverter described by ItemConverterType. + If null, the default constructor is used. + When non-null, there must be a constructor defined in the JsonConverter that exactly matches the number, + order, and type of these parameters. + + + [JsonContainer(ItemConverterType = typeof(MyContainerConverter), ItemConverterParameters = new object[] { 123, "Four" })] + + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable types; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Instructs the to use the specified when serializing the member or class. + + + + + Gets the of the converter. + + The of the converter. + + + + The parameter list to use when constructing the JsonConverter described by ConverterType. + If null, the default constructor is used. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Initializes a new instance of the class. + + Type of the converter. + Parameter list to use when constructing the JsonConverter. Can be null. + + + + Instructs the how to serialize the object. + + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Specifies the settings on a object. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than TypeNameHandling.None. + + The type name handling. + + + + Gets or sets how metadata properties are used during deserialization. + + The metadata properties handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the equality comparer used by the serializer when comparing references. + + The equality comparer. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets a function that creates the used by the serializer when resolving references. + + A function that creates the used by the serializer when resolving references. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Get or set how and values are formatted when writing JSON text, and the expected date format when reading JSON text. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Get or set how special floating point numbers, e.g. , + and , + are written as JSON. + + + + + Get or set how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Gets or sets the reader's character buffer pool. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a []. + + A [] or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Instructs the to always serialize the member with the specified name. + + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + The parameter list to use when constructing the JsonConverter described by ItemConverterType. + If null, the default constructor is used. + When non-null, there must be a constructor defined in the JsonConverter that exactly matches the number, + order, and type of these parameters. + + + [JsonProperty(ItemConverterType = typeof(MyContainerConverter), ItemConverterParameters = new object[] { 123, "Four" })] + + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization of a member. + + The numeric order of serialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets or sets the writer's character array pool. + + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + A flag to indicate whether the text should be escaped when it is written as a JSON property name. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + The exception thrown when an error occurs while reading JSON text. + + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + The exception thrown when an error occurs while reading JSON text. + + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Represents a collection of . + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized JSON data. + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets or sets a value indicating whether multiple pieces of JSON content can + be read from a continuous stream without erroring. + + + true to support reading multiple pieces of JSON content; otherwise false. The default is false. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Get or set how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Get or set how custom date formatted strings are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a []. + + A [] or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Gets or sets a function that creates default . + Default settings are automatically used by serialization methods on , + and and on . + To serialize without using any default settings create a with + . + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + The string escape handling. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using formatting. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using formatting and a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a type, formatting and . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be used. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifing the type is optional. + + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using formatting and . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a type, formatting and . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be used. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifing the type is optional. + + + A JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the JSON string. + + + + Deserializes the JSON to a .NET object using . + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the given anonymous type using . + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type using a collection of . + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using . + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using a collection of . + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using . + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string using . + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + + + + Serializes the XML node to a JSON string. + + The node to serialize. + A JSON string of the XmlNode. + + + + Serializes the XML node to a JSON string using formatting. + + The node to serialize. + Indicates how the output is formatted. + A JSON string of the XmlNode. + + + + Serializes the XML node to a JSON string using formatting and omits the root object if is true. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XmlNode. + + + + Deserializes the XmlNode from a JSON string. + + The JSON string. + The deserialized XmlNode + + + + Deserializes the XmlNode from a JSON string nested in a root elment specified by . + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XmlNode + + + + Deserializes the XmlNode from a JSON string nested in a root elment specified by + and writes a .NET array attribute for collections. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XmlNode + + + + Serializes the to a JSON string. + + The node to convert to JSON. + A JSON string of the XNode. + + + + Serializes the to a JSON string using formatting. + + The node to convert to JSON. + Indicates how the output is formatted. + A JSON string of the XNode. + + + + Serializes the to a JSON string using formatting and omits the root object if is true. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XNode. + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment specified by . + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment specified by + and writes a .NET array attribute for collections. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XNode + + + + The exception thrown when an error occurs during JSON serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the equality comparer used by the serializer when comparing references. + + The equality comparer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than TypeNameHandling.None. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets how metadata properties are used during deserialization. + + The metadata properties handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Get or set how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Get or set how special floating point numbers, e.g. , + and , + are written as JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Get or set how and values are formatted when writing JSON text, and the expected date format when reading JSON text. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance. + The will not use default settings + from . + + + A new instance. + The will not use default settings + from . + + + + + Creates a new instance using the specified . + The will not use default settings + from . + + The settings to be applied to the . + + A new instance using the specified . + The will not use default settings + from . + + + + + Creates a new instance. + The will use default settings + from . + + + A new instance. + The will use default settings + from . + + + + + Creates a new instance using the specified . + The will use default settings + from as well as the specified . + + The settings to be applied to the . + + A new instance using the specified . + The will use default settings + from as well as the specified . + + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the JSON structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the JSON structure + to a Stream using the specified . + + The used to write the JSON structure. + The to serialize. + + + + Serializes the specified and writes the JSON structure + to a Stream using the specified . + + The used to write the JSON structure. + The to serialize. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifing the type is optional. + + + + + Serializes the specified and writes the JSON structure + to a Stream using the specified . + + The used to write the JSON structure. + The to serialize. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifing the type is optional. + + + + + Serializes the specified and writes the JSON structure + to a Stream using the specified . + + The used to write the JSON structure. + The to serialize. + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + Specifies type name handling options for the . + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than TypeNameHandling.None. + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Specifies the type of JSON token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Get or set how special floating point numbers, e.g. , + and , + are written to JSON text. + + + + + Get or set how and values are formatting when writing JSON text. + + + + + Gets or sets the culture used when writing JSON. Defaults to . + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a JSON object. + + + + + Writes the end of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + A flag to indicate whether the text should be escaped when it is written as a JSON property name. + + + + Writes the end of the current JSON object or array. + + + + + Writes the current token and its children. + + The to read the token from. + + + + Writes the current token. + + The to read the token from. + A flag indicating whether the current token's children should be written. + + + + Writes the token and its value. + + The to write. + + The value to write. + A value is only required for tokens that have an associated value, e.g. the property name for . + A null value can be passed to the method for token's that don't have a value, e.g. . + + + + Writes the token. + + The to write. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Sets the state of the JsonWriter, + + The JsonToken being written. + The value being written. + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone/Newtonsoft.Json.XML.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone/Newtonsoft.Json.XML.meta new file mode 100644 index 00000000..7623f101 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Standalone/Newtonsoft.Json.XML.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d6807fedb8dcaf04682d2c84f0ab753f +timeCreated: 1466788355 +licenseType: Store +TextScriptImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows.meta new file mode 100644 index 00000000..0c47db53 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 1418141139a6ac443b18cb05c0643a29 +folderAsset: yes +timeCreated: 1466788345 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.XML b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.XML new file mode 100644 index 00000000..ed0eec5f --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.XML @@ -0,0 +1,7977 @@ + + + + Newtonsoft.Json + + + + + Represents a BSON Oid (object id). + + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Initializes a new instance of the class. + + The Oid value. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized JSON data. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a JSON array. + + + + + Writes the beginning of a JSON object. + + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a F# discriminated union type to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + + + + + + + + + + + + + + Converts an ExpandoObject to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + + + + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Gets or sets a value indicating whether integer values are allowed. + + true if integers are allowed; otherwise, false. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + true if the written enum text will be camel case; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Json Converter for Vector2, Vector3 and Vector4. Only serializes x, y, (z) and (w) properties. + + + + + Default Constructor - All Vector types enabled by default + + + + + Selectively enable Vector types + + Use for Vector2 objects + Use for Vector3 objects + Use for Vector4 objects + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts XML to and from JSON. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produces multiple root elements. + + The name of the deserialize root element. + + + + Gets or sets a flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attibute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the attributeName is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + True if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable types; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Specifies float format handling options when writing special floating point numbers, e.g. , + and with . + + + + + Write special floating point values as strings in JSON, e.g. "NaN", "Infinity", "-Infinity". + + + + + Write special floating point values as symbols in JSON, e.g. NaN, Infinity, -Infinity. + Note that this will produce non-valid JSON. + + + + + Write special floating point values as the property's default value in JSON, e.g. 0.0 for a property, null for a property. + + + + + Specifies how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Floating point numbers are parsed to . + + + + + Floating point numbers are parsed to . + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Provides an interface for using pooled arrays. + + The array type content. + + + + Rent a array from the pool. This array must be returned when it is no longer needed. + + The minimum required length of the array. The returned array may be longer. + The rented array from the pool. This array must be returned when it is no longer needed. + + + + Return an array to the pool. + + The array that is being returned. + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Instructs the how to serialize the collection. + + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Instructs the how to serialize the object. + + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + The parameter list to use when constructing the JsonConverter described by ItemConverterType. + If null, the default constructor is used. + When non-null, there must be a constructor defined in the JsonConverter that exactly matches the number, + order, and type of these parameters. + + + [JsonContainer(ItemConverterType = typeof(MyContainerConverter), ItemConverterParameters = new object[] { 123, "Four" })] + + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Gets or sets a function that creates default . + Default settings are automatically used by serialization methods on , + and and on . + To serialize without using any default settings create a with + . + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + The string escape handling. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using formatting. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using formatting and a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a type, formatting and . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be used. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifing the type is optional. + + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using formatting and . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a type, formatting and . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be used. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifing the type is optional. + + + A JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string. + Serialization will happen on a new thread. + + The object to serialize. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string using formatting. + Serialization will happen on a new thread. + + The object to serialize. + Indicates how the output is formatted. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string using formatting and a collection of . + Serialization will happen on a new thread. + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be used. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the JSON string. + + + + Deserializes the JSON to a .NET object using . + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the given anonymous type using . + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type using a collection of . + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using . + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using a collection of . + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using . + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Asynchronously deserializes the JSON to the specified .NET type. + Deserialization will happen on a new thread. + + The type of the object to deserialize to. + The JSON to deserialize. + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type using . + Deserialization will happen on a new thread. + + The type of the object to deserialize to. + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type. + Deserialization will happen on a new thread. + + The JSON to deserialize. + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type using . + Deserialization will happen on a new thread. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string using . + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + + + + Asynchronously populates the object with values from the JSON string using . + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + + A task that represents the asynchronous populate operation. + + + + + Serializes the to a JSON string. + + The node to convert to JSON. + A JSON string of the XNode. + + + + Serializes the to a JSON string using formatting. + + The node to convert to JSON. + Indicates how the output is formatted. + A JSON string of the XNode. + + + + Serializes the to a JSON string using formatting and omits the root object if is true. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XNode. + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment specified by . + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment specified by + and writes a .NET array attribute for collections. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XNode + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Instructs the to use the specified when serializing the member or class. + + + + + Gets the of the converter. + + The of the converter. + + + + The parameter list to use when constructing the JsonConverter described by ConverterType. + If null, the default constructor is used. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Initializes a new instance of the class. + + Type of the converter. + Parameter list to use when constructing the JsonConverter. Can be null. + + + + Represents a collection of . + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during JSON serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Instructs the to deserialize properties with no matching class member into the specified collection + and write values during serialization. + + + + + Gets or sets a value that indicates whether to write extension data when serializing the object. + + + true to write extension data when serializing the object; otherwise, false. The default is true. + + + + + Gets or sets a value that indicates whether to read extension data when deserializing the object. + + + true to read extension data when deserializing the object; otherwise, false. The default is true. + + + + + Initializes a new instance of the class. + + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Instructs the how to serialize the object. + + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Instructs the to always serialize the member with the specified name. + + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + The parameter list to use when constructing the JsonConverter described by ItemConverterType. + If null, the default constructor is used. + When non-null, there must be a constructor defined in the JsonConverter that exactly matches the number, + order, and type of these parameters. + + + [JsonProperty(ItemConverterType = typeof(MyContainerConverter), ItemConverterParameters = new object[] { 123, "Four" })] + + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization of a member. + + The numeric order of serialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized JSON data. + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets or sets a value indicating whether multiple pieces of JSON content can + be read from a continuous stream without erroring. + + + true to support reading multiple pieces of JSON content; otherwise false. The default is false. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Get or set how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Get or set how custom date formatted strings are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a []. + + A [] or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + The exception thrown when an error occurs while reading JSON text. + + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Instructs the to always serialize the member, and require the member has a value. + + + + + The exception thrown when an error occurs during JSON serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the equality comparer used by the serializer when comparing references. + + The equality comparer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than TypeNameHandling.None. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets how metadata properties are used during deserialization. + + The metadata properties handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Get or set how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Get or set how special floating point numbers, e.g. , + and , + are written as JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Get or set how and values are formatted when writing JSON text, and the expected date format when reading JSON text. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance. + The will not use default settings + from . + + + A new instance. + The will not use default settings + from . + + + + + Creates a new instance using the specified . + The will not use default settings + from . + + The settings to be applied to the . + + A new instance using the specified . + The will not use default settings + from . + + + + + Creates a new instance. + The will use default settings + from . + + + A new instance. + The will use default settings + from . + + + + + Creates a new instance using the specified . + The will use default settings + from as well as the specified . + + The settings to be applied to the . + + A new instance using the specified . + The will use default settings + from as well as the specified . + + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the JSON structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the JSON structure + to a Stream using the specified . + + The used to write the JSON structure. + The to serialize. + + + + Serializes the specified and writes the JSON structure + to a Stream using the specified . + + The used to write the JSON structure. + The to serialize. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifing the type is optional. + + + + + Serializes the specified and writes the JSON structure + to a Stream using the specified . + + The used to write the JSON structure. + The to serialize. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifing the type is optional. + + + + + Serializes the specified and writes the JSON structure + to a Stream using the specified . + + The used to write the JSON structure. + The to serialize. + + + + Specifies the settings on a object. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than TypeNameHandling.None. + + The type name handling. + + + + Gets or sets how metadata properties are used during deserialization. + + The metadata properties handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the equality comparer used by the serializer when comparing references. + + The equality comparer. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets a function that creates the used by the serializer when resolving references. + + A function that creates the used by the serializer when resolving references. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Get or set how and values are formatted when writing JSON text, and the expected date format when reading JSON text. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Get or set how special floating point numbers, e.g. , + and , + are written as JSON. + + + + + Get or set how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Gets or sets the reader's character buffer pool. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a []. + + A [] or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets or sets the writer's character array pool. + + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + A flag to indicate whether the text should be escaped when it is written as a JSON property name. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Specifies the type of JSON token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Get or set how special floating point numbers, e.g. , + and , + are written to JSON text. + + + + + Get or set how and values are formatting when writing JSON text. + + + + + Gets or sets the culture used when writing JSON. Defaults to . + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a JSON object. + + + + + Writes the end of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + A flag to indicate whether the text should be escaped when it is written as a JSON property name. + + + + Writes the end of the current JSON object or array. + + + + + Writes the current token and its children. + + The to read the token from. + + + + Writes the current token. + + The to read the token from. + A flag indicating whether the current token's children should be written. + + + + Writes the token and its value. + + The to write. + + The value to write. + A value is only required for tokens that have an associated value, e.g. the property name for . + A null value can be passed to the method for token's that don't have a value, e.g. . + + + + Writes the token. + + The to write. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Sets the state of the JsonWriter, + + The JsonToken being written. + The value being written. + + + + The exception thrown when an error occurs while reading JSON text. + + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Specifies how JSON comments are handled when loading JSON. + + + + + Ignore comments. + + + + + Load comments as a with type . + + + + + Specifies how line information is handled when loading JSON. + + + + + Ignore line information. + + + + + Load line information. + + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every token in the source collection. + + + + Returns a collection of tokens that contains every token in the source collection, and the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains every token in the source collection, the ancestors of every token in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every token in the source collection. + + + + Returns a collection of tokens that contains every token in the source collection, and the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains every token in the source collection, and the descendants of every token in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every token in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every token in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every token in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every token in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every token in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every token in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Represents a JSON array. + + + + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Copies to. + + The array. + Index of the array. + + + + Gets a value indicating whether the is read-only. + + true if the is read-only; otherwise, false. + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Represents a JSON constructor. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Represents a token that can contain other tokens. + + + + + Occurs when the items list of the collection has changed, or the collection is reset. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Raises the event. + + The instance containing the event data. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Returns a collection of the tokens that contain this token, and all descendant tokens of this token, in document order. + + An containing this token, and all the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Merge the specified content into this . + + The content to be merged. + + + + Merge the specified content into this using . + + The content to be merged. + The used to merge the content. + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Gets the with the specified key. + + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Represents a JSON object. + + + + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets the node type for this . + + The type. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Represents a JSON property. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Represents a raw JSON string. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Specifies the settings used when loading JSON. + + + + + Gets or sets how JSON comments are handled when loading JSON. + + The JSON comment handling. + + + + Gets or sets how JSON line info is handled when loading JSON. + + The JSON line info handling. + + + + Specifies the settings used when merging JSON. + + + + + Gets or sets the method used when merging JSON arrays. + + The method used when merging JSON arrays. + + + + Gets or sets how how null value properties are merged. + + How null value properties are merged. + + + + Represents an abstract JSON token. + + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the path of the JSON token. + + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of tokens that contain this token, and the ancestors of this token. + + A collection of tokens that contain this token, and the ancestors of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to []. + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from [] to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Creates a from a . + + An positioned at the token to read into this . + The used to load the JSON. + If this is null, default load settings will be used. + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + The used to load the JSON. + If this is null, default load settings will be used. + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects a using a JPath expression. Selects the token that matches the object path. + + + A that contains a JPath expression. + + A , or null. + + + + Selects a using a JPath expression. Selects the token that matches the object path. + + + A that contains a JPath expression. + + A flag to indicate whether an error should be thrown if no tokens are found when evaluating part of the expression. + A . + + + + Selects a collection of elements using a JPath expression. + + + A that contains a JPath expression. + + An that contains the selected elements. + + + + Selects a collection of elements using a JPath expression. + + + A that contains a JPath expression. + + A flag to indicate whether an error should be thrown if no tokens are found when evaluating part of the expression. + An that contains the selected elements. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Adds an object to the annotation list of this . + + The annotation to add. + + + + Get the first annotation object of the specified type from this . + + The type of the annotation to retrieve. + The first annotation object that matches the specified type, or null if no annotation is of the specified type. + + + + Gets the first annotation object of the specified type from this . + + The of the annotation to retrieve. + The first annotation object that matches the specified type, or null if no annotation is of the specified type. + + + + Gets a collection of annotations of the specified type for this . + + The type of the annotations to retrieve. + An that contains the annotations for this . + + + + Gets a collection of annotations of the specified type for this . + + The of the annotations to retrieve. + An of that contains the annotations that match the specified type for this . + + + + Removes the annotations of the specified type from this . + + The type of annotations to remove. + + + + Removes the annotations of the specified type from this . + + The of annotations to remove. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized JSON data. + + + + + Gets the at the reader's current position. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Gets the path of the current JSON token. + + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets the at the writer's current position. + + + + + Gets the token being writen. + + The token being writen. + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Creates a null value. + + A null value. + + + + Creates a undefined value. + + A undefined value. + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Specifies how JSON arrays are merged together. + + + + Concatenate arrays. + + + Union arrays, skipping items that already exist. + + + Replace all array items. + + + Merge array items together, matched by index. + + + + Specifies how null value properties are merged. + + + + + The content's null value properties will be ignored during merging. + + + + + The content's null value properties will be merged. + + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies metadata property handling options for the . + + + + + Read metadata properties located at the start of a JSON object. + + + + + Read metadata properties located anywhere in a JSON object. Note that this setting will impact performance. + + + + + Do not try to read metadata properties. + + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Specifies reference handling options for the . + Note that references cannot be preserved when a value is set via a non-default constructor such as types that implement ISerializable. + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + The property is not required but it cannot be a null value. + + + + + Allows users to control class loading and mandate what class to load. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object + The type of the object the formatter creates a new instance of. + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Resolves member mappings for a type, camel casing property names. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + Get and set values for a using dynamic methods. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Used by to resolves a for a given . + + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly improve performance with multiple resolver instances because expensive reflection will only + happen once. This setting can cause unexpected behavior if different instances of the resolver are suppose to produce different + results. When set to false it is highly recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Resolved name of the property. + + + + Resolves the key of the dictionary. By default is used to resolve dictionary keys. + + Key of the dictionary. + Resolved key of the dictionary. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Provides information surrounding an error. + + + + + Gets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Provides data for the Error event. + + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Provides methods to get attributes. + + + + + Returns a collection of all of the attributes, or an empty collection if there are no attributes. + + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Returns a collection of attributes, identified by type, or an empty collection if there are no attributes. + + The type of the attributes. + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + Represents a trace writer. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Contract details for a used by the . + + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Gets or sets the function used to create the object. When set this function will override . + + The function used to create the object. + + + + Gets a value indicating whether the creator has a parameter with the collection values. + + true if the creator has a parameter with the collection values; otherwise, false. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Handles serialization callback events. + + The object that raised the callback event. + The streaming context. + + + + Handles serialization error callback events. + + The object that raised the callback event. + The streaming context. + The error context. + + + + Sets extension data for an object during deserialization. + + The object to set extension data on. + The extension data key. + The extension data value. + + + + Gets extension data for an object during serialization. + + The object to set extension data on. + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets all methods called immediately after deserialization of the object. + + The methods called immediately after deserialization of the object. + + + + Gets or sets all methods called during deserialization of the object. + + The methods called during deserialization of the object. + + + + Gets or sets all methods called after serialization of the object graph. + + The methods called after serialization of the object graph. + + + + Gets or sets all methods called before serialization of the object. + + The methods called before serialization of the object. + + + + Gets or sets all method called when an error is thrown during the serialization of the object. + + The methods called when an error is thrown during the serialization of the object. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Contract details for a used by the . + + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets or sets the dictionary key resolver. + + The dictionary key resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Gets or sets the function used to create the object. When set this function will override . + + The function used to create the object. + + + + Gets a value indicating whether the creator has a parameter with the dictionary values. + + true if the creator has a parameter with the dictionary values; otherwise, false. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Gets the object's properties. + + The object's properties. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets a collection of instances that define the parameters used with . + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Gets or sets the function used to create the object. When set this function will override . + This function is called with a collection of arguments which are defined by the collection. + + The function used to create the object. + + + + Gets or sets the extension data setter. + + + + + Gets or sets the extension data getter. + + + + + Gets or sets the extension data value type. + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization of a member. + + The numeric order of serialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the for this property. + + The for this property. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets or sets the member converter. + + The member converter. + + + + Gets or sets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets or sets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets or sets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets or sets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets or sets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets or sets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets or sets the property null value handling. + + The null value handling. + + + + Gets or sets the property default value handling. + + The default value handling. + + + + Gets or sets the property reference loop handling. + + The reference loop handling. + + + + Gets or sets the property object creation handling. + + The object creation handling. + + + + Gets or sets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be deserialized. + + A predicate used to determine whether the property should be deserialized. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Lookup and create an instance of the JsonConverter type described by the argument. + + The JsonConverter type to create. + Optional arguments to pass to an initializing constructor of the JsonConverter. + If null, the default constructor is used. + + + + Create a factory function that can be used to create instances of a JsonConverter described by the + argument type. The returned function can then be used to either invoke the converter's default ctor, or any + parameterized constructors by way of an object array. + + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Represents a method that constructs an object. + + The object type to create. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Provides methods to get attributes from a , , or . + + + + + Initializes a new instance of the class. + + The instance to get attributes for. This parameter should be a , , or . + + + + Returns a collection of all of the attributes, or an empty collection if there are no attributes. + + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Returns a collection of attributes, identified by type, or an empty collection if there are no attributes. + + The type of the attributes. + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Specifies what messages to output for the class. + + + + + Output no tracing and debugging messages. + + + + + Output error-handling messages. + + + + + Output warnings and error-handling messages. + + + + + Output informational messages, warnings, and error-handling messages. + + + + + Output all debugging and tracing messages. + + + + + Specifies type name handling options for the . + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than TypeNameHandling.None. + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic that returns a result + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Returns a Restrictions object which includes our current restrictions merged + with a restriction limiting our type + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + + Indicates the method that will be used during deserialization for locating and loading assemblies. + + + + + In simple mode, the assembly used during deserialization need not match exactly the assembly used during serialization. Specifically, the version numbers need not match as the LoadWithPartialName method is used to load the assembly. + + + + + In full mode, the assembly used during deserialization must match exactly the assembly used during serialization. The Load method of the Assembly class is used to load the assembly. + + + + diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.XML.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.XML.meta new file mode 100644 index 00000000..c4619d0d --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.XML.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 36f7323c55864364d8bb88c736e4bca6 +timeCreated: 1466788355 +licenseType: Store +TextScriptImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.dll b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.dll new file mode 100644 index 00000000..05a0d4bf Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.dll differ diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.dll.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.dll.meta new file mode 100644 index 00000000..c2149e34 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Assemblies/Windows/Newtonsoft.Json.dll.meta @@ -0,0 +1,106 @@ +fileFormatVersion: 2 +guid: 9b6ba260dada0ea4a871a42011f8b87d +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + '': Linux + second: + enabled: 0 + settings: + CPU: x86 + - first: + '': OSXIntel + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + '': OSXIntel64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + '': SamsungTV + second: + enabled: 0 + settings: + STV_MODEL: STANDARD_13 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: AnyCPU + DontProcess: False + PlaceholderPath: Assets/JsonDotNet/Assemblies/Standalone/Newtonsoft.Json.dll + SDK: AnySDK + ScriptingBackend: DotNet + - first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation.meta new file mode 100644 index 00000000..cda8075c --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 76f828f47ce26cc43991113c6a39dbbf +folderAsset: yes +timeCreated: 1466010535 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation/Json Net for Unity 2.0.1.pdf b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation/Json Net for Unity 2.0.1.pdf new file mode 100644 index 00000000..4f7651d4 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation/Json Net for Unity 2.0.1.pdf differ diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation/Json Net for Unity 2.0.1.pdf.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation/Json Net for Unity 2.0.1.pdf.meta new file mode 100644 index 00000000..e5d02572 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/Documentation/Json Net for Unity 2.0.1.pdf.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4e7d9a07cc3f02a41a575406e7230846 +timeCreated: 1466788421 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/JsonDotNet201Source.zip b/popcorn/Assets/Joypac/Plugins/JsonDotNet/JsonDotNet201Source.zip new file mode 100644 index 00000000..23b699a4 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/JsonDotNet/JsonDotNet201Source.zip differ diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/JsonDotNet201Source.zip.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/JsonDotNet201Source.zip.meta new file mode 100644 index 00000000..c846be60 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/JsonDotNet201Source.zip.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9a6f8c7c1ea72ce46831c5e1b6150d0c +timeCreated: 1466790933 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/link.xml b/popcorn/Assets/Joypac/Plugins/JsonDotNet/link.xml new file mode 100644 index 00000000..cf188f82 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/link.xml @@ -0,0 +1,7 @@ + + + + + + + \ No newline at end of file diff --git a/popcorn/Assets/Joypac/Plugins/JsonDotNet/link.xml.meta b/popcorn/Assets/Joypac/Plugins/JsonDotNet/link.xml.meta new file mode 100644 index 00000000..1e0e2734 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/JsonDotNet/link.xml.meta @@ -0,0 +1,6 @@ +fileFormatVersion: 2 +guid: 06314f49bdda26043963578d60a0a7ee +TextScriptImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS.meta b/popcorn/Assets/Joypac/Plugins/iOS.meta new file mode 100644 index 00000000..2d5a4a88 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ef2ae1f44594f408cb57bc027cbe5e98 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross.meta new file mode 100644 index 00000000..712eb892 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 02de0c971c6014102a3da7c1eb9aa2a1 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework.meta new file mode 100644 index 00000000..32b13fff --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework.meta @@ -0,0 +1,34 @@ +fileFormatVersion: 2 +guid: 20bf89edf63224b70a5c223e319b33f5 +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + iPhone: iOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/Info.plist b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/Info.plist new file mode 100644 index 00000000..2095e0f3 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/Info.plist differ diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/Info.plist.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/Info.plist.meta new file mode 100644 index 00000000..1f277c28 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/Info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 902ffbd141207461ab4f27ca677c020f +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/JPCross b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/JPCross new file mode 100644 index 00000000..1aa3f9c4 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/JPCross differ diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/JPCross.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/JPCross.meta new file mode 100644 index 00000000..d1c9c604 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/JPCross.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 338f7f814b7284fe4bd3d986a2ffae86 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature.meta new file mode 100644 index 00000000..2c2dc9a7 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9e939c1013d4a4617819219c415c255b +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeDirectory b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeDirectory new file mode 100644 index 00000000..26dd0fea Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeDirectory differ diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeDirectory.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeDirectory.meta new file mode 100644 index 00000000..67f32697 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeDirectory.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 32000e40cf0ec4932aae1c58147b5a7b +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements new file mode 100644 index 00000000..dbf9d614 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements differ diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements-1 b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements-1 new file mode 100644 index 00000000..43199112 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements-1 differ diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements-1.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements-1.meta new file mode 100644 index 00000000..dccc9acb --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements-1.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 78552f805c29e4e7cad9f70fa1afd95f +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements.meta new file mode 100644 index 00000000..89c8bade --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeRequirements.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 19c02374ac6244a1e8f6f20f93bd6884 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeResources b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeResources new file mode 100644 index 00000000..30808788 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeResources @@ -0,0 +1,101 @@ + + + + + files + + Info.plist + + w0bEX6JGoAunhl4ys9v8FKezrUE= + + + files2 + + rules + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^version.plist$ + + + rules2 + + .*\.dSYM($|/) + + weight + 11 + + ^(.*/)?\.DS_Store$ + + omit + + weight + 2000 + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^Info\.plist$ + + omit + + weight + 20 + + ^PkgInfo$ + + omit + + weight + 20 + + ^embedded\.provisionprofile$ + + weight + 20 + + ^version\.plist$ + + weight + 20 + + + + diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeResources.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeResources.meta new file mode 100644 index 00000000..84f67956 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeResources.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 6e5d44f3fcd9247f18e722f4e92a4064 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeSignature b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeSignature new file mode 100644 index 00000000..e69de29b diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeSignature.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeSignature.meta new file mode 100644 index 00000000..5ff8df9c --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPCross.framework/_CodeSignature/CodeSignature.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: ea59802ca58e54bfab6f260069e3d377 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle.meta new file mode 100644 index 00000000..f6f4a6f5 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle.meta @@ -0,0 +1,34 @@ +fileFormatVersion: 2 +guid: 9682abe2a940a4944bb8e8c70f56add8 +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + iPhone: iOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle/2.png b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle/2.png new file mode 100644 index 00000000..1cf2e39c Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle/2.png differ diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle/2.png.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle/2.png.meta new file mode 100644 index 00000000..fecd0b5a --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JPVideoCross.bundle/2.png.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: a9f1e4d5b444f451a96455619dba9e96 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JoypacCross.cs b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JoypacCross.cs new file mode 100644 index 00000000..19a99fe1 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JoypacCross.cs @@ -0,0 +1,201 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using System.Runtime.InteropServices; +using System; +using AOT; +public enum crossType : int +{ + + //启动图 + launchCross, + //视频 + videoCross + +}; +#if CROSS +public class JoypacCross : MonoBehaviour { + + //public static System.Action m_successCallback; + //public static System.Action m_failCallback; + + //private Action m_crossCallback; + + + + private static JoypacCross s_cross; + public static JoypacCross Instance{ + get{ + if (s_cross == null) { + s_cross = new JoypacCross (); + } + return s_cross; + } + } + + void Start() + { + DontDestroyOnLoad(this); + } + + // Update is called once per frame + void Update() + { + + } + +#if UNITY_IOS + + //视频cross + [DllImport("__Internal")] + private static extern void initVideoCrossWithString(float x,float y,float width, float height,float degrees,string jsonStr); + + [DllImport("__Internal")] + private static extern void ExtraAttributs(string bgColor,string titleColor,string desTextColor,string btnBgColor,string btnTextColor); + + [DllImport("__Internal")] + private static extern bool isReadyVideoCross(); + + [DllImport("__Internal")] + private static extern void showVideoCross (string position); + + [DllImport("__Internal")] + private static extern void removeVideoCross (); + + [DllImport("__Internal")] + private static extern bool isShowingVideoCross (); + + //启动图cross + [DllImport("__Internal")] + private static extern void initLaunchCross(string jsonStr); + + [DllImport("__Internal")] + private static extern void showLaunchCross(string position); + + [DllImport("__Internal")] + private static extern void removeLaunchCross(); + + [DllImport("__Internal")] + private static extern bool isShowingLanuchCross(); + + [DllImport("__Internal")] + private static extern void showLaunchCrossWithFrame(float x,float y,float width, float height,string position); + + [DllImport("__Internal")] + private static extern void sendUrl2Adjust(string urlString,string position); + + + [MonoPInvokeCallback(typeof(Action))] + //public static void CallbackFunc(){ + // if (s_cross.m_crossCallback != null) s_cross.m_crossCallback (); + //} + public void HideCross() + { +#if UNITY_EDITOR + return; +#endif + removeLaunchCross(); + } + public void InitCross(crossType type, float x, float y, float width,float height,float degress,string jsonStr){ + + if (type == crossType.launchCross) + { + Debug.Log("初始化启动图交叉推广 json数组" + jsonStr); + initLaunchCross(jsonStr); + + }else { + Debug.Log("初始化视频交叉推广 json数据" + jsonStr); + initVideoCrossWithString(x, y, width, height, degress, jsonStr); + } + } + + public void AddExtraAttributs(string bgColor,string titleColor,string desTextColor,string btnBgColor,string btnTextColor){ + + Debug.Log("调用视频交叉推广控件属性参数 bgColor:"+bgColor +" titleColor:"+titleColor+" desTextColor:"+desTextColor+" btnBgColor:"+btnBgColor+" btnTextColor:"+btnTextColor); + ExtraAttributs (bgColor, titleColor, desTextColor, btnBgColor, btnTextColor); + + } + + public bool IsReadyVideoCross(){ + + return isReadyVideoCross(); + + } + + + public void ShowCross(crossType type,string position) + { + + if (type == crossType.launchCross) + { + Debug.Log("展示启动图交叉推广"); + showLaunchCross(position); + }else + { + Debug.Log("展示视频交叉推广"); + showVideoCross(position); + + } + } + + public void RemoveCross(crossType type) + { + + if (type == crossType.launchCross) + { + Debug.Log("删除启动图交叉推广"); + removeLaunchCross(); + + } + else + { + Debug.Log("删除视频交叉推广"); + removeVideoCross(); + + } + } + + + public bool IsShowingCross(crossType type) + { + + if (type == crossType.launchCross) + { + Debug.Log("是否正在展示启动图交叉推广" + isShowingLanuchCross()); + return isShowingLanuchCross(); + } + else + { + Debug.Log("是否正在展示视频交叉推广" + isShowingVideoCross()); + return isShowingVideoCross(); + + + } + } + + public void ShowLaunchCrossWithFrame(float x,float y,float width,float height,string position){ + + showLaunchCrossWithFrame(x,y,width,height,position); + } + + public void SendUrl2Adjust(string urlString,string position){ + + sendUrl2Adjust(urlString,position); + } + + //void LoadCrossSuccessCallBack(){ + + // Debug.Log ("call joypac cross 成功回调"); + // if(m_successCallback != null) m_successCallback(); + + //} + + //void LoadCrossFailCallBack(){ + //if(m_failCallback != null) m_failCallback(); + //} + + #endif + +} + +#endif diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JoypacCross.cs.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JoypacCross.cs.meta new file mode 100644 index 00000000..ba1e94ce --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/JoypacCross.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 29e27d186b990478ba4f3f115446c42d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle.meta new file mode 100644 index 00000000..727d4762 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle.meta @@ -0,0 +1,34 @@ +fileFormatVersion: 2 +guid: 61c546e51bcbc4fb3a82b25d497aa969 +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + iPhone: iOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle/close.png b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle/close.png new file mode 100644 index 00000000..0bbb2f77 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle/close.png differ diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle/close.png.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle/close.png.meta new file mode 100644 index 00000000..77c49a80 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPCross/UMeng.bundle/close.png.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 10dde7dee9b3b4f3380e92ba47125d97 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPThird.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPThird.meta new file mode 100644 index 00000000..b4c86515 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPThird.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fbad1d74d4e6446bf98f90b6166fc6a9 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPThird/JoypacInterface.mm b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/JoypacInterface.mm new file mode 100644 index 00000000..f4534798 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/JoypacInterface.mm @@ -0,0 +1,240 @@ +//#include +//#include "Thirdparty/SDWebImage/UIButton+WebCache.h" +#import +#import + +@interface JoypacInterface : NSObject { + //int _crossIndex; + //NSArray* _crossArray; + //UIView* _crossBGView; + UIButton* _buttonContent; + UIButton* _buttonClose; + //bool _isSHownCross; + NSString* _crossAppUrl; +} + + +#define SCREEN_WIDTH [[UIScreen mainScreen] bounds].size.width +#define SCREEN_HEIGHT [[UIScreen mainScreen] bounds].size.height +//-(void)initCross:(NSString*)json_str; +@end + +@implementation JoypacInterface + + +//-(void)initCross:(NSString*)json_str{ +// // _crossIndex = 0; +// NSLog(@"initCross, json_str = %@",json_str); +// NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; +// _crossIndex = [defaults integerForKey:@"CROSS_INDEX"]; +// +// _crossArray = nil; +// NSData *data= [json_str dataUsingEncoding:NSUTF8StringEncoding]; +// NSError *error = nil; +// id jsonObject = [NSJSONSerialization JSONObjectWithData:data +// options:NSJSONReadingAllowFragments +// error:&error]; +// if ([jsonObject isKindOfClass:[NSArray class]]){ +// _crossArray = (NSArray *)jsonObject; +// NSLog(@"Dersialized JSON Array = %@", _crossArray); +// } else { +// NSLog(@"An error happened while deserializing the JSON data."); +// return; +// } +// +// float bt_width = (SCREEN_WIDTH= [_crossArray count]) +// _crossIndex =0; +// NSArray *arr = [_crossArray objectAtIndex:_crossIndex]; +// if(arr && [arr count]==2) +// { +// NSURL *url = [ [ NSURL alloc ] initWithString: [arr objectAtIndex:0]]; +// [_buttonContent sd_setImageWithURL:url forState:UIControlStateNormal completed:^(UIImage * _Nullable image, NSError * _Nullable error, SDImageCacheType cacheType, NSURL * _Nullable imageURL) { +// if(image) +// { +// [[UIApplication sharedApplication].keyWindow.rootViewController.view addSubview:_crossBGView]; +// _crossAppUrl = [arr objectAtIndex:1]; +// _crossIndex++; +// _isSHownCross = true; +// [[NSUserDefaults standardUserDefaults] setInteger:_crossIndex forKey:@"CROSS_INDEX"]; +// callback(); +// } +// }]; +// } +// else{ +// NSLog(@"An error happened while deserializing the JSON data 2."); +// } +// } +// +//} +// +//-(void)hideCross{ +// [_crossBGView removeFromSuperview]; +//} + +-(void)btnClick{ + NSURL *url = [ [ NSURL alloc ] initWithString: _crossAppUrl ]; + // [[UIApplication sharedApplication] openURL:url]; + NSURLRequest *req = [NSURLRequest requestWithURL:url]; + + [NSURLConnection sendAsynchronousRequest:req queue:[NSOperationQueue mainQueue] completionHandler:^(NSURLResponse *response, NSData *data, NSError *connectionError) { + if (connectionError) { + NSLog(@"error:%@",connectionError); + }else{ + NSLog(@"response:%@",response); + if(response.URL) + [[UIApplication sharedApplication] openURL:response.URL]; + } + }]; +} + +- (void)handHTTPWithUrl:(NSString *)urlString{ + + NSURL *url = [NSURL URLWithString:[NSString stringWithFormat:@"%@?idfa=%@",urlString,[self getIDFA]]]; + NSMutableURLRequest *quest = [NSMutableURLRequest requestWithURL:url]; + quest.HTTPMethod = @"GET"; + NSURLSessionConfiguration *config = [NSURLSessionConfiguration defaultSessionConfiguration]; + config.requestCachePolicy = NSURLRequestReloadIgnoringLocalCacheData; + NSURLSession *urlSession = [NSURLSession sessionWithConfiguration:config delegate:self delegateQueue:[NSOperationQueue currentQueue]]; + + NSURLSessionDataTask *task = [urlSession dataTaskWithRequest:quest completionHandler:^(NSData * _Nullable data, NSURLResponse * _Nullable response, NSError * _Nullable error) { + + }]; + + [task resume]; +} + +- (void)URLSession:(NSURLSession *)session task:(NSURLSessionTask *)task +willPerformHTTPRedirection:(NSHTTPURLResponse *)response + newRequest:(NSURLRequest *)request + completionHandler:(void (^)(NSURLRequest * _Nullable))completionHandler;{ + + NSHTTPURLResponse *urlResponse = (NSHTTPURLResponse *)response; + + if (urlResponse.statusCode == 302) { + + NSDictionary *dic = urlResponse.allHeaderFields; + + if (dic[@"Location"]) { + + [self handHTTPWithUrl:dic[@"Location"]]; + + } + } +} + +- (void)sendTaskWithUrlStr:(NSString *)str{ + + [self handHTTPWithUrl:str]; + +} + +- (NSString *)getIDFA{ + + if ([ASIdentifierManager sharedManager].isAdvertisingTrackingEnabled) { + return [[ASIdentifierManager sharedManager].advertisingIdentifier UUIDString]; + }else{ + return @"00000000-0000-0000-0000-000000000000"; + } + +} + +@end + +extern "C" { + typedef void (*CallBack)(); + + char* OnlineStringParamUmeng(const char* _key){ +// NSString* onlineValue = [UMOnlineConfig stringParams:[NSString stringWithUTF8String:_key]]; +// if (onlineValue == nil) { +// return strdup(""); +// } + return strdup(""); + } + void ShowReviewAlert (){ + [SKStoreReviewController requestReview]; +} + void InitOnlineParams(const char* _appkey, bool _logEnable){ +// [UMOnlineConfig initWithAppkey:[NSString stringWithUTF8String:_appkey]]; +// [UMOnlineConfig fetchData]; +// [UMOnlineConfig setLogEnabled:_logEnable]; + } + + char * ScreenBounds(){ + CGRect rect = [[UIScreen mainScreen] bounds]; + CGSize size = rect.size; + CGFloat width = size.width; + CGFloat height = size.height; + NSString *sizeString = [NSString stringWithFormat:@"%f_%f", width, height]; + return strdup([sizeString UTF8String]); + } + + static JoypacInterface* s_joypacInterface = NULL; + +// void InitCross(const char* _url){ +// if(s_joypacInterface == NULL) s_joypacInterface = [[JoypacInterface alloc] init]; +// +// [s_joypacInterface initCross:[NSString stringWithUTF8String:_url]]; +// } +// +// void ShowCross(CallBack _callback){ +// [s_joypacInterface showCross:^{ +// _callback(); +// }]; +// } + +// void SendUrl2Adjust(const char * _adjustUrl){ +// if(s_joypacInterface == NULL) s_joypacInterface = [[JoypacInterface alloc] init]; +// [s_joypacInterface handHTTPWithUrl:[NSString stringWithUTF8String:_adjustUrl]]; +// } +} + + diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPThird/JoypacInterface.mm.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/JoypacInterface.mm.meta new file mode 100644 index 00000000..141ade72 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/JoypacInterface.mm.meta @@ -0,0 +1,37 @@ +fileFormatVersion: 2 +guid: 717ece85ddd0540dbbe59346bee9ade6 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty.meta new file mode 100644 index 00000000..d7828f79 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 7827f64e6e3534d43a80bafe1e103759 +folderAsset: yes +timeCreated: 1554809427 +licenseType: Pro +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty/ReYunTracking.a b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty/ReYunTracking.a new file mode 100755 index 00000000..75b4e736 Binary files /dev/null and b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty/ReYunTracking.a differ diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty/ReYunTracking.a.meta b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty/ReYunTracking.a.meta new file mode 100644 index 00000000..7a40c5e2 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JPThird/Thirdparty/ReYunTracking.a.meta @@ -0,0 +1,32 @@ +fileFormatVersion: 2 +guid: acb3950be72d04b4987fa4c723d354fa +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JoypacService-info.plist b/popcorn/Assets/Joypac/Plugins/iOS/JoypacService-info.plist new file mode 100644 index 00000000..c2eb8645 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JoypacService-info.plist @@ -0,0 +1,34 @@ + + + + + JoypacAppId + 0cc787bfde + JoypacAppName + 打败小偷 + topOnAppId + a5e5cd93c49329 + topOnAppKey + d78b587989ce58c20e6df748f53e3f31 + bannerStatus + 1 + bannerPlacement + b5e5cdc1c064e4 + nativeStatus + 1 + nativePlacement + b5e5cdbfeb5771 + splashStatus + 1 + splashPlacement + b5e5cdc0cd7d74 + JPSplashPlacement + 打败小偷SP + rewardVideoStatus + 1 + rewardVideoPlacement + b5e5cdb8fb04d7 + interstitialConfig + [{"adOrder": "1", "maxTimeInterval": "0", "minTimeInterval": "0", "status": "1", "unitID": "b5e5cdba1689cf", "name": "打败小偷IV"}] + + \ No newline at end of file diff --git a/popcorn/Assets/Joypac/Plugins/iOS/JoypacService-info.plist.meta b/popcorn/Assets/Joypac/Plugins/iOS/JoypacService-info.plist.meta new file mode 100644 index 00000000..65080289 --- /dev/null +++ b/popcorn/Assets/Joypac/Plugins/iOS/JoypacService-info.plist.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 7a2adb514d28043a6aa0af4fb9ecb85f +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Purchase.meta b/popcorn/Assets/Joypac/Purchase.meta new file mode 100644 index 00000000..9259e69d --- /dev/null +++ b/popcorn/Assets/Joypac/Purchase.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 01a26765f189b4ef594f677e014209da +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Purchase/JoypacIAP.cs b/popcorn/Assets/Joypac/Purchase/JoypacIAP.cs new file mode 100644 index 00000000..efee3307 --- /dev/null +++ b/popcorn/Assets/Joypac/Purchase/JoypacIAP.cs @@ -0,0 +1,90 @@ +/*create by :闫婷婷 + * date :2020/6/1 + */ +#if ENABLE_IAP +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using Joypac; +using UnityEngine.Purchasing; +/// +/// Joypac iap. IAPListener IAP监听。玩家付费过程中退出游戏,再进游戏的处理。 +/// +public class JoypacIAP : MonoBehaviour +{ + string removeAdsId = "homealone.removeads"; + private static JoypacIAP instance; + private static Transform obj; + public static JoypacIAP Instance + { + get + { + if (instance == null) + { + if(obj==null) + { + obj = Instantiate(Resources.Load("Joypac/JoypacIAP")); + } + instance= obj.gameObject.GetComponent(); + } + return instance; + } + } + public void Init() + { + + } + private void Awake() + { + Object.DontDestroyOnLoad(this.gameObject); + } + private void OnEnable() + { +#if !ENABLE_IAP + Destroy(this.gameObject); +#endif + } + public void OnPurchaseComplete(Product product) + { + Debug.LogError(product.definition.id); + if (product.definition.id == removeAdsId) + { + JoypacUtils.SetRemoveAdBought(); + } + PopLoadingView.Hide(); + } + public void OnPurchaseFailed(Product product, PurchaseFailureReason reason) + { + //Debug.LogError(product.definition.id); + PopLoadingView.Hide(); + } + //使用方法 + /* + + 1.监听 + JoypacIAP.Instance.iAPListener.onPurchaseComplete.RemoveAllListeners(); + JoypacIAP.Instance.iAPListener.onPurchaseComplete.AddListener( + (product) => + { + Debug.Log("buy onPurchaseComplete productid="+ inappId_apple); + Buy(true, callBack, buyCount, addBonus); + }); + JoypacIAP.Instance.iAPListener.onPurchaseComplete.AddListener + (JoypacIAP.Instance.OnPurchaseComplete); + + JoypacIAP.Instance.iAPListener.onPurchaseFailed.RemoveAllListeners(); + JoypacIAP.Instance.iAPListener.onPurchaseFailed.AddListener( + (product, fail) => + { + Debug.Log("buy onPurchaseFailed productid=" + inappId_apple+ " fail:"+ fail); + Buy(false, callBack, buyCount, addBonus); + }); + JoypacIAP.Instance.iAPListener.onPurchaseFailed.AddListener + (JoypacIAP.Instance.OnPurchaseFailed); + + 2.购买 + CodelessIAPStoreListener.Instance.InitiatePurchase(inappId_apple); + */ + */ +} +#endif \ No newline at end of file diff --git a/popcorn/Assets/Joypac/Purchase/JoypacIAP.cs.meta b/popcorn/Assets/Joypac/Purchase/JoypacIAP.cs.meta new file mode 100644 index 00000000..90129153 --- /dev/null +++ b/popcorn/Assets/Joypac/Purchase/JoypacIAP.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 84fbf5302be1e42b7b2785722e371dca +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/popcorn/Assets/Joypac/Purchase/JoypacIAPButton.cs b/popcorn/Assets/Joypac/Purchase/JoypacIAPButton.cs new file mode 100644 index 00000000..d0f5a48f --- /dev/null +++ b/popcorn/Assets/Joypac/Purchase/JoypacIAPButton.cs @@ -0,0 +1,73 @@ +/*create by :闫婷婷 + * date :2020/6/1 + */ +#if ENABLE_IAP +using System.Collections; +using System.Collections.Generic; +using UnityEditor; +using UnityEngine; +using UnityEngine.Purchasing; +using UnityEngine.UI; +public class JoypacIAPButton : MonoBehaviour +{ + private IAPButton m_iapButton; + public IAPButton iAPButton + { + get + { + if(m_iapButton==null) + { + if(this.gameObject!=null&& this.gameObject.GetComponent() != null) + { + m_iapButton= this.gameObject.GetComponent(); + } + else + { + Debug.LogError("this.gameObject != null && this.gameObject.GetComponent() != null"); + } + } + return m_iapButton; + } + } + + public virtual void Start() + { + if(this.gameObject.GetComponent