Skip to content

Commit

Permalink
[ios] Fix the issue where the SkeletonBounds instance couldn’t be ini…
Browse files Browse the repository at this point in the history
…tialized (#2669)

Co-authored-by: liqiang <[email protected]>
  • Loading branch information
kikiloveswift and liqiang authored Nov 14, 2024
1 parent 648170f commit 000df07
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
1 change: 1 addition & 0 deletions spine-cpp/spine-cpp-lite/spine-cpp-lite.h
Original file line number Diff line number Diff line change
Expand Up @@ -1051,6 +1051,7 @@ SPINE_CPP_LITE_EXPORT void spine_texture_region_set_original_width(spine_texture
SPINE_CPP_LITE_EXPORT int32_t spine_texture_region_get_original_height(spine_texture_region textureRegion);
SPINE_CPP_LITE_EXPORT void spine_texture_region_set_original_height(spine_texture_region textureRegion, int32_t originalHeight);

// @ignore
SPINE_CPP_LITE_EXPORT spine_skeleton_bounds spine_skeleton_bounds_create();
SPINE_CPP_LITE_EXPORT void spine_skeleton_bounds_dispose(spine_skeleton_bounds bounds);
SPINE_CPP_LITE_EXPORT void spine_skeleton_bounds_update(spine_skeleton_bounds bounds, spine_skeleton skeleton, spine_bool updateAabb);
Expand Down
6 changes: 6 additions & 0 deletions spine-ios/Sources/Spine/Spine.Generated+Extensions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -313,3 +313,9 @@ internal enum FileSource {
extension String: Error {

}

public extension SkeletonBounds {
static func create() -> SkeletonBounds {
return SkeletonBounds(spine_skeleton_bounds_create())
}
}
5 changes: 0 additions & 5 deletions spine-ios/Sources/Spine/Spine.Generated.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1757,11 +1757,6 @@ public final class SkeletonBounds: NSObject {
return spine_skeleton_bounds_get_height(wrappee)
}

@discardableResult
public func create() -> SkeletonBounds {
return .init(spine_skeleton_bounds_create())
}

public func dispose() {
if disposed { return }
disposed = true
Expand Down

0 comments on commit 000df07

Please sign in to comment.