Skip to content

Commit 7e0a043

Browse files
tankorsmashminggo
authored andcommitted
Fix warning for converting int to float (#18672)
Could use a static_cast but it doesn't seem to be the style
1 parent edee972 commit 7e0a043

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cocos/ui/UITabControl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ namespace ui {
290290
* get tab header's width
291291
* @return header's width
292292
*/
293-
float getHeaderWidth() const { return _headerWidth; }
293+
float getHeaderWidth() const { return (float)_headerWidth; }
294294

295295
/**
296296
* set header height, affect all tab

0 commit comments

Comments
 (0)