mirror of
https://github.com/geode-sdk/geode.git
synced 2024-11-14 19:15:05 -05:00
Merge branch '1.4.0-dev' into android
This commit is contained in:
commit
41ae88ae5b
19 changed files with 199 additions and 62 deletions
12
.github/ISSUE_TEMPLATE/bug-report.yml
vendored
12
.github/ISSUE_TEMPLATE/bug-report.yml
vendored
|
@ -1,7 +1,17 @@
|
|||
name: Bug Report
|
||||
description: Report a bug where something is not working as expected in Geode Loader (not specific mods), which does not crash the game.
|
||||
description: Report a Geode bug (not mods themselves) where something is not working as expected in Geode Loader (not mods created by others), which does not crash the game.
|
||||
labels: [ "unverified", "bug" ]
|
||||
body:
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: Geode Issue
|
||||
description: |
|
||||
The Geode repository is for issues of *Geode Loader*, not individual mods created by other developers.
|
||||
When submitting a bug report, please make sure that the bug is *actually* related to ***Geode Loader itself*** and not to a mod or mod combination.
|
||||
Failing to do this will get your issue *closed without explanation*.
|
||||
options:
|
||||
- label: I confirm that this bug is NOT related to a mod but directly to Geode Loader itself.
|
||||
required: true
|
||||
- type: dropdown
|
||||
id: platform
|
||||
attributes:
|
||||
|
|
13
.github/ISSUE_TEMPLATE/crash-report.yml
vendored
13
.github/ISSUE_TEMPLATE/crash-report.yml
vendored
|
@ -1,7 +1,18 @@
|
|||
name: Crash Report
|
||||
description: Report a bug that crashes the game or prevents startup caused by Geode Loader (not individual mods).
|
||||
description: Report a Geode bug (not mods themselves) that crashes the game or prevents startup caused by Geode Loader (not mods created by others).
|
||||
labels: [ "unverified", "crash" ]
|
||||
body:
|
||||
- type: input
|
||||
id: geode-confirmation
|
||||
attributes:
|
||||
label: Geode Issue
|
||||
description: |
|
||||
The Geode repository is for issues of *Geode Loader*, not individual mods created by other developers.
|
||||
When submitting a crash report, please make sure that the crash is *actually* related to ***Geode Loader itself*** and not to a mod or mod combination, after you do that type in "confirm" in the input field above.
|
||||
Failing to do this will get your issue *closed without explanation*.
|
||||
placeholder: "Please, read the text below."
|
||||
validations:
|
||||
required: true
|
||||
- type: dropdown
|
||||
id: platform
|
||||
attributes:
|
||||
|
|
4
.github/workflows/build.yml
vendored
4
.github/workflows/build.yml
vendored
|
@ -146,13 +146,13 @@ jobs:
|
|||
files: geode-win/XInput9_1_0.dll geode-win/Geode.dll geode-win/GeodeUpdater.exe geode-win/Geode.lib geode-win/Geode.pdb
|
||||
dest: geode-${{ steps.ref.outputs.hash }}-win.zip
|
||||
|
||||
- name: Zip Windows Resources
|
||||
- name: Zip Resources
|
||||
uses: vimtor/action-zip@v1.1
|
||||
with:
|
||||
files: geode-mac/resources
|
||||
dest: resources.zip
|
||||
|
||||
- name: Update Nightly Release
|
||||
- name: Update Development Release
|
||||
uses: andelf/nightly-release@main
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
|
14
CHANGELOG.md
14
CHANGELOG.md
|
@ -1,9 +1,21 @@
|
|||
# Geode Changelog
|
||||
|
||||
## v1.3.5
|
||||
* Follow redirect in web::utils functions (a942a45)
|
||||
* Lots of bindings
|
||||
* Make codegen symbols private visibility (696a2ca)
|
||||
* Add deadstrip to macos (0d62940)
|
||||
* Readd the nullptr check in InstallListPopup::createCells (499f256)
|
||||
* Fix garagelayer ids on not logged in users (dd0179c)
|
||||
|
||||
## v1.3.4
|
||||
* Implement string setting character filters (cf8fbba)
|
||||
* Update bindings
|
||||
|
||||
## v1.3.3
|
||||
* Reunify resources.zip (81de161)
|
||||
|
||||
## v1.3.2
|
||||
## v1.3.2
|
||||
* Fix alignment of some textures (8f39c38)
|
||||
* Bring back unknown problems (0663569)
|
||||
* Fix some Windows 7 incompatibility (2d2bdd1)
|
||||
|
|
|
@ -185,7 +185,14 @@ target_include_directories(GeodeCodegenSources PRIVATE
|
|||
${GEODE_LOADER_PATH}/include/Geode/cocos/extensions
|
||||
${GEODE_LOADER_PATH}/include/Geode/fmod
|
||||
)
|
||||
set_target_properties(GeodeCodegenSources PROPERTIES CXX_VISIBILITY_PRESET hidden)
|
||||
target_compile_features(GeodeCodegenSources PUBLIC cxx_std_20)
|
||||
|
||||
if (APPLE)
|
||||
target_compile_options(GeodeCodegenSources PUBLIC -ffunction-sections -fdata-sections)
|
||||
target_link_options(GeodeCodegenSources PUBLIC -dead_strip)
|
||||
endif()
|
||||
|
||||
if (NOT GEODE_DISABLE_PRECOMPILED_HEADERS)
|
||||
target_precompile_headers(GeodeCodegenSources INTERFACE
|
||||
"${GEODE_LOADER_PATH}/include/Geode/Bindings.hpp"
|
||||
|
@ -218,6 +225,11 @@ else()
|
|||
set(GEODE_PLATFORM_BIN_PATH ${GEODE_BIN_PATH}/${PROJECT_VERSION}/${GEODE_PLATFORM_BINARY})
|
||||
endif()
|
||||
|
||||
if (WIN32)
|
||||
# This allows you to compile in debug mode
|
||||
add_compile_definitions(_HAS_ITERATOR_DEBUGGING=0)
|
||||
endif()
|
||||
|
||||
|
||||
if (PROJECT_IS_TOP_LEVEL)
|
||||
add_subdirectory(loader)
|
||||
|
|
|
@ -124,6 +124,11 @@ class cocos2d::CCClippingNode {
|
|||
//}
|
||||
|
||||
[[link(win, android)]]
|
||||
class cocos2d::CCConfiguration {
|
||||
void gatherGPUInfo() = mac 0x2a6e10;
|
||||
}
|
||||
|
||||
[[link(win)]]
|
||||
class cocos2d::CCDelayTime {
|
||||
static cocos2d::CCDelayTime* create(float) = mac 0x1f4380;
|
||||
}
|
||||
|
@ -383,6 +388,7 @@ class cocos2d::CCKeypadHandler {
|
|||
|
||||
[[link(win, android)]]
|
||||
class cocos2d::CCLabelBMFont {
|
||||
CCLabelBMFont() = mac 0x347b60;
|
||||
static cocos2d::CCLabelBMFont* create(char const*, char const*) = mac 0x347660;
|
||||
auto limitLabelWidth(float, float, float) = mac 0x34a6e0, ios 0x21b740;
|
||||
auto setFntFile(char const*) = mac 0x34a5f0;
|
||||
|
@ -390,7 +396,7 @@ class cocos2d::CCLabelBMFont {
|
|||
static auto create() = mac 0x3473f0;
|
||||
|
||||
virtual auto init() = mac 0x347b10, ios 0x2198e0;
|
||||
bool initWithString(const char* str, const char* fnt, float width, cocos2d::CCTextAlignment align, cocos2d::CCPoint offset);
|
||||
bool initWithString(const char* str, const char* fnt, float width, cocos2d::CCTextAlignment align, cocos2d::CCPoint offset) = mac 0x347710;
|
||||
virtual auto setScaleX(float) = mac 0x34a5b0, ios 0x21b6e8;
|
||||
virtual auto setScaleY(float) = mac 0x34a5d0, ios 0x21b714;
|
||||
virtual auto setScale(float) = mac 0x34a590, ios 0x21b6bc;
|
||||
|
@ -634,6 +640,12 @@ class cocos2d::CCNode {
|
|||
virtual auto cleanup() = mac 0x123100, ios 0x15e3a4;
|
||||
auto convertToNodeSpace(cocos2d::CCPoint const&) = mac 0x124750, ios 0x15f55c;
|
||||
auto convertToWorldSpace(cocos2d::CCPoint const&) = mac 0x124790;
|
||||
cocos2d::CCPoint convertToNodeSpaceAR(cocos2d::CCPoint const& worldPoint) {
|
||||
return convertToNodeSpace(worldPoint) - getAnchorPointInPoints();
|
||||
}
|
||||
cocos2d::CCPoint convertToWorldSpaceAR(cocos2d::CCPoint const& nodePoint) {
|
||||
return convertToWorldSpace(nodePoint + getAnchorPointInPoints());
|
||||
}
|
||||
static cocos2d::CCNode* create() = mac 0x1230a0;
|
||||
virtual auto draw() = mac 0x123840, ios 0x15e974;
|
||||
auto getActionByTag(int) = mac 0x123ee0;
|
||||
|
@ -1132,6 +1144,7 @@ class cocos2d::CCTouchHandler {
|
|||
[[link(win, android)]]
|
||||
class cocos2d::CCTransitionFade {
|
||||
static cocos2d::CCTransitionFade* create(float, cocos2d::CCScene*) = mac 0x8ea30, ios 0x12c244;
|
||||
virtual bool initWithDuration(float t, cocos2d::CCScene* scene, cocos2d::ccColor3B const& color) = mac 0x8e930;
|
||||
}
|
||||
|
||||
[[link(win, android)]]
|
||||
|
@ -1265,13 +1278,15 @@ class cocos2d {
|
|||
static auto ccDrawSolidRect(cocos2d::CCPoint, cocos2d::CCPoint, cocos2d::_ccColor4F) = mac 0xecf00;
|
||||
static auto ccGLEnableVertexAttribs(unsigned int) = mac 0x1ae740;
|
||||
static auto ccGLBindTexture2D(GLuint) = mac 0x1ae610;
|
||||
static auto ccGLBindTexture2DN(GLuint, GLuint) = mac 0x1ae650;
|
||||
static float ccpDistance(cocos2d::CCPoint const&, cocos2d::CCPoint const&) = mac 0x1aaf90;
|
||||
static auto ccDrawLine(cocos2d::CCPoint const&, cocos2d::CCPoint const&) = mac 0xeccc0;
|
||||
static void ccDrawPoly(cocos2d::CCPoint const*, unsigned int, bool) = mac 0xed0a0;
|
||||
static void ccDrawColor4B(GLubyte, GLubyte, GLubyte, GLubyte) = mac 0xeddd0;
|
||||
static void CCMessageBox(const char* msg, const char* title) = mac 0xbabc0;
|
||||
}
|
||||
|
||||
[[link(win, android)]]
|
||||
[[link(win)]]
|
||||
class DS_Dictionary {
|
||||
DS_Dictionary() = mac 0xbe9a0;
|
||||
~DS_Dictionary() = mac 0x393c30;
|
||||
|
|
|
@ -296,6 +296,10 @@ class CCAnimatedSprite : cocos2d::CCSprite {
|
|||
class CCAnimateFrameCache : cocos2d::CCObject {
|
||||
static CCAnimateFrameCache* sharedSpriteFrameCache() = mac 0x2e4df0, win 0x158f0;
|
||||
void addSpriteFramesWithFile(const char* file) = win 0x159b0;
|
||||
|
||||
cocos2d::CCDictionary* m_unknown1;
|
||||
cocos2d::CCDictionary* m_unknown2;
|
||||
cocos2d::CCDictionary* m_unknown3;
|
||||
}
|
||||
|
||||
[[link(android)]]
|
||||
|
@ -951,6 +955,8 @@ class CommentUploadDelegate {
|
|||
|
||||
[[link(android)]]
|
||||
class ConfigureHSVWidget : cocos2d::CCNode {
|
||||
bool init(int abs, cocos2d::ccHSVValue val) = win 0x4a3f0, mac 0x237310;
|
||||
void updateLabels() = win 0x4adf0, mac 0x237df0;
|
||||
cocos2d::CCLabelBMFont* m_hueLabel;
|
||||
cocos2d::CCLabelBMFont* m_saturationLabel;
|
||||
cocos2d::CCLabelBMFont* m_brightnessLabel;
|
||||
|
@ -1083,7 +1089,7 @@ class CustomizeObjectLayer : FLAlertLayer, TextInputDelegate, HSVWidgetPopupDele
|
|||
void onClose(cocos2d::CCObject*) = mac 0xdf660, win 0x57ac0;
|
||||
void updateSelected(int channelID) = mac 0xe0970, win 0x57850;
|
||||
bool init(GameObject* target, cocos2d::CCArray* targets) = mac 0xdd560, win 0x53e00;
|
||||
void onHSV(cocos2d::CCObject* sender) = win 0x567c0;
|
||||
void onHSV(cocos2d::CCObject* sender) = win 0x567c0, mac 0xdfa00;
|
||||
void toggleVisible() = mac 0xe1140, win 0x56fb0;
|
||||
void highlightSelected(ButtonSprite* target) = mac 0xe0aa0, win 0x579d0;
|
||||
void updateCustomColorLabels() = mac 0xdff40, win 0x576d0;
|
||||
|
@ -1092,8 +1098,8 @@ class CustomizeObjectLayer : FLAlertLayer, TextInputDelegate, HSVWidgetPopupDele
|
|||
// inlined in most places
|
||||
void updateChannelLabel(int channel) = mac 0xe06e0, win 0x56f50;
|
||||
virtual void hsvPopupClosed(HSVWidgetPopup* popup, cocos2d::ccHSVValue value) = win 0x56990;
|
||||
virtual void colorSelectClosed(cocos2d::CCNode*) = mac 0xe0c70, win 0x564a0;
|
||||
virtual void textChanged(CCTextInputNode* input) = mac 0xe16a0, win 0x574d0;
|
||||
virtual void colorSelectClosed(cocos2d::CCNode*) = mac 0xe0610, win 0x564a0;
|
||||
virtual void textChanged(CCTextInputNode* input) = mac 0xe1470, win 0x574d0;
|
||||
inline CustomizeObjectLayer() {}
|
||||
~CustomizeObjectLayer() = win 0x53c30;
|
||||
|
||||
|
@ -1199,7 +1205,7 @@ class DrawGridLayer : cocos2d::CCLayer {
|
|||
}
|
||||
|
||||
bool init(cocos2d::CCNode* grid, LevelEditorLayer* editor) = win 0x16c4d0;
|
||||
void draw() = win 0x16ce90;
|
||||
virtual void draw() = win 0x16ce90, mac 0xa3c40;
|
||||
virtual void update(float) = win 0x16cd80;
|
||||
void clearPlayerPoints() {
|
||||
m_playerNodePoints->removeAllObjects();
|
||||
|
@ -1339,7 +1345,7 @@ class EditorPauseLayer : CCBlockLayer, FLAlertLayerProtocol {
|
|||
bool init(LevelEditorLayer*) = mac 0x13c7a0, win 0x730e0, ios 0x280cb8;
|
||||
void onExitEditor(cocos2d::CCObject* sender) = mac 0x13f180, win 0x75660;
|
||||
void playStep2() = mac 0x13f040, win 0x75440;
|
||||
void onResume(cocos2d::CCObject* sender) = win 0x74fe0;
|
||||
void onResume(cocos2d::CCObject* sender) = mac 0x13e170, win 0x74fe0;
|
||||
void onSaveAndPlay(cocos2d::CCObject* sender) = mac 0x13e1b0, win 0x753d0;
|
||||
void onSaveAndExit(cocos2d::CCObject* sender) = mac 0x13e230, win 0x75620;
|
||||
void onSave(cocos2d::CCObject* sender) = mac 0x13e290, win 0x755a0;
|
||||
|
@ -1371,6 +1377,8 @@ class EditorUI : cocos2d::CCLayer, FLAlertLayerProtocol, ColorSelectDelegate, GJ
|
|||
|
||||
void create(LevelEditorLayer*) = mac 0x8a80, win 0x76270;
|
||||
cocos2d::CCArray* createCustomItems() = mac 0x1ddf0, win 0x7a370;
|
||||
void onDeleteCustomItem(cocos2d::CCObject* pSender) = win 0x7a280, mac 0x29860;
|
||||
void onNewCustomItem(cocos2d::CCObject* pSender) = win 0x79fd0, mac 0x24480;
|
||||
void deselectAll() = mac 0x1f300, win 0x86af0;
|
||||
void onDeselectAll(cocos2d::CCObject*) = mac 0x19cd0, win 0x86ac0;
|
||||
void disableButton(CreateMenuItem*) = mac 0x1c0f0, win 0x78af0;
|
||||
|
@ -1420,8 +1428,8 @@ class EditorUI : cocos2d::CCLayer, FLAlertLayerProtocol, ColorSelectDelegate, GJ
|
|||
void onCreateButton(cocos2d::CCObject* sender) = mac 0x1fd70, win 0x854f0;
|
||||
CCMenuItemSpriteExtra* getSpriteButton(const char* sprite, cocos2d::SEL_MenuHandler callback, cocos2d::CCMenu* menu, float scale) = mac 0xb500, win 0x78bf0;
|
||||
cocos2d::CCPoint offsetForKey(int objID) = win 0x92310;
|
||||
void updateDeleteMenu() = win 0x7c5d0;
|
||||
void updateCreateMenu(bool updateTab) = mac 0x1e960, win 0x85530;
|
||||
void updateDeleteMenu() = win 0x7c5d0, mac 0x1e960;
|
||||
void updateCreateMenu(bool updateTab) = mac 0x1ba80, win 0x85530;
|
||||
void toggleMode(cocos2d::CCObject* sender) = mac 0x187b0, win 0x7ad20;
|
||||
void zoomIn(cocos2d::CCObject* sender) = mac 0xc0c0, win 0x877c0;
|
||||
void zoomOut(cocos2d::CCObject* sender) = mac 0xc120, win 0x87830;
|
||||
|
@ -1489,6 +1497,7 @@ class EditorUI : cocos2d::CCLayer, FLAlertLayerProtocol, ColorSelectDelegate, GJ
|
|||
void sliderChanged(cocos2d::CCObject* slider) = mac 0xaed0, win 0x78cc0;
|
||||
void repositionObjectsToCenter(cocos2d::CCArray* objs, cocos2d::CCPoint center, bool ignoreGroupParent) = mac 0x1fcd0, win 0x88410;
|
||||
virtual void draw() = win 0x8fbe0;
|
||||
float valueFromXPos(float val) = win 0x78e30, mac 0x1c810;
|
||||
|
||||
bool m_isPlayingMusic;
|
||||
EditButtonBar* m_buttonBar;
|
||||
|
@ -1698,9 +1707,12 @@ class EffectGameObject : GameObject {
|
|||
}
|
||||
|
||||
[[link(android)]]
|
||||
class EndLevelLayer {
|
||||
class EndLevelLayer : cocos2d::CCLayer {
|
||||
static EndLevelLayer* create() = mac 0x2787d0, win 0x94b50;
|
||||
|
||||
void customSetup() = win 0x94cb0;
|
||||
const char* getCoinString(void* p0) = win 0x96270;
|
||||
const char* getEndText() = win 0x964A0;
|
||||
void onMenu(cocos2d::CCObject* sender) = mac 0x27a500, win 0x96c10;
|
||||
void onEdit(cocos2d::CCObject* sender) = mac 0x27a640, win 0x96d30;
|
||||
}
|
||||
|
@ -1833,8 +1845,8 @@ class FriendRequestDelegate {}
|
|||
|
||||
[[link(android)]]
|
||||
class FriendsProfilePage : FLAlertLayer, FLAlertLayerProtocol, UploadActionDelegate, UploadPopupDelegate, UserListDelegate {
|
||||
static FriendsProfilePage* create(UserListType) = win 0x9ce80;
|
||||
bool init(UserListType) = win 0x9cf30;
|
||||
static FriendsProfilePage* create(UserListType) = win 0x9ce80, mac 0x3a9570;
|
||||
bool init(UserListType) = win 0x9cf30, mac 0x3a9770;
|
||||
}
|
||||
|
||||
[[link(android)]]
|
||||
|
@ -1867,11 +1879,16 @@ class GJAccountLoginDelegate {
|
|||
[[link(android)]]
|
||||
class GJAccountManager : cocos2d::CCNode {
|
||||
static GJAccountManager* sharedState() = mac 0x85070, win 0x107d50;
|
||||
static GJAccountManager* get() {
|
||||
return GJAccountManager::sharedState();
|
||||
}
|
||||
gd::string getGJP() = mac 0x89520, win 0x10abb0;
|
||||
|
||||
PAD = mac 0x8, win 0x4;
|
||||
gd::string m_password;
|
||||
gd::string m_username;
|
||||
int m_accountID;
|
||||
int m_playerID;
|
||||
}
|
||||
|
||||
[[link(android)]]
|
||||
|
@ -2375,7 +2392,7 @@ class GJGameLevel : cocos2d::CCNode {
|
|||
void getLengthKey(int) = mac 0x2dbba0;
|
||||
void getNormalPercent() = mac 0x2b8b20;
|
||||
void levelWasAltered() = mac 0x2db530, win 0xbd550;
|
||||
void savePercentage(int, bool, int, int, bool) = mac 0x2db700;
|
||||
void savePercentage(int, bool, int, int, bool) = mac 0x2db700, win 0xbd5c0;
|
||||
void dataLoaded(DS_Dictionary* dict) = mac 0x2dc0e0, win 0xbded0, ios 0x6fca4;
|
||||
GJDifficulty getAverageDifficulty() = win 0xbd9b0;
|
||||
gd::string getUnpackedLevelDescription() = mac 0x2DDB50, win 0xbf890;
|
||||
|
@ -2691,22 +2708,22 @@ class GJScaleControl : cocos2d::CCLayer {
|
|||
virtual void ccTouchMoved(cocos2d::CCTouch*, cocos2d::CCEvent*) = mac 0x31e60, win 0x94840;
|
||||
virtual void ccTouchEnded(cocos2d::CCTouch*, cocos2d::CCEvent*) = mac 0x31fb0, win 0x94940;
|
||||
virtual void ccTouchCancelled(cocos2d::CCTouch*, cocos2d::CCEvent*) = mac 0x32060, win 0x2dea0; // shared with many others
|
||||
void updateLabel(float value) = win 0x94990;
|
||||
void updateLabel(float value) = win 0x94990, mac 0x31c90;
|
||||
void loadValues(GameObject* obj, cocos2d::CCArray* objs) = win 0x94590, mac 0x24f40;
|
||||
|
||||
Slider* m_slider;
|
||||
unsigned int m_touchID;
|
||||
float m_value;
|
||||
PAD = mac 0x8, win 0x4;
|
||||
bool m_shouldSnapAt1;
|
||||
cocos2d::CCLabelBMFont* m_label;
|
||||
GJScaleControlDelegate* m_delegate;
|
||||
}
|
||||
|
||||
[[link(android)]]
|
||||
class GJScaleControlDelegate {
|
||||
virtual void scaleChanged(float) {}
|
||||
virtual void scaleChangeBegin() {}
|
||||
virtual void scaleChangeEnded() {}
|
||||
virtual void scaleChanged(float) {}
|
||||
}
|
||||
|
||||
[[link(android)]]
|
||||
|
@ -3725,7 +3742,7 @@ class GameToolbox {
|
|||
static cocos2d::CCDictionary* stringSetupToDict(gd::string text, char const* delimeter) = mac 0x28d700, win 0x272a0;
|
||||
static CCMenuItemToggler* createToggleButton(gd::string text, cocos2d::SEL_MenuHandler onToggled, bool isToggled, cocos2d::CCMenu* toggleMenu, cocos2d::CCPoint position, cocos2d::CCNode* callbackTarget, cocos2d::CCNode* labelParent, cocos2d::CCArray* toggleArray) = mac 0x28bc90, win 0x25fe0;
|
||||
static CCMenuItemToggler* createToggleButton(gd::string text, cocos2d::SEL_MenuHandler onToggled, bool isToggled, cocos2d::CCMenu* toggleMenu, cocos2d::CCPoint position, cocos2d::CCNode* callbackTarget, cocos2d::CCNode* labelParent, float checkboxScale, float labelSize, float maxWidth, cocos2d::CCPoint labelOffset, const char* unknown, bool anchorHorizontally, int toggleTag, cocos2d::CCArray* toggleArray) = mac 0x28bdd0, win 0x25fe0;
|
||||
static cocos2d::ccColor3B transformColor(cocos2d::ccColor3B const& src, cocos2d::ccHSVValue hsv) = win 0x26a60;
|
||||
static cocos2d::ccColor3B transformColor(cocos2d::ccColor3B const& src, cocos2d::ccHSVValue hsv) = win 0x26a60, mac 0x28c950;
|
||||
static void alignItemsHorisontally(cocos2d::CCArray* array, float pad, cocos2d::CCPoint start, bool idk) = win 0x25b20;
|
||||
static gd::map<gd::string, gd::string> stringSetupToMap(gd::string, char const*) = mac 0x28d4c0;
|
||||
static cocos2d::ccColor3B multipliedColorValue(cocos2d::ccColor3B color1, cocos2d::ccColor3B color2, float factor) = win 0x26CE0;
|
||||
|
@ -3768,7 +3785,7 @@ class GhostTrailEffect {}
|
|||
|
||||
[[link(android)]]
|
||||
class HSVWidgetPopup : FLAlertLayer {
|
||||
bool init(cocos2d::_ccHSVValue value, HSVWidgetPopupDelegate* delegate, gd::string title);
|
||||
bool init(cocos2d::_ccHSVValue value, HSVWidgetPopupDelegate* delegate, gd::string title) = win 0x49f10, mac 0x236d30;
|
||||
void onClose(cocos2d::CCObject* sender) = win 0x4a280;
|
||||
|
||||
ConfigureHSVWidget* m_configureWidget;
|
||||
|
@ -3793,7 +3810,7 @@ class HardStreak : cocos2d::CCDrawNode {
|
|||
void reset() = mac 0x5c930;
|
||||
void resumeStroke() = mac 0x5c210;
|
||||
void stopStroke() = mac 0x5c8f0, win 0x14e460;
|
||||
void updateStroke(float) = mac 0x5c240, win 0x14e530;
|
||||
callback void updateStroke(float) = mac 0x5c240, win 0x14e530;
|
||||
|
||||
cocos2d::CCArray* m_pointsArr;
|
||||
cocos2d::CCPoint m_currentPoint;
|
||||
|
@ -3897,6 +3914,7 @@ class LevelBrowserLayer : cocos2d::CCLayer, LevelManagerDelegate, FLAlertLayerPr
|
|||
void updateLevelsLabel() = mac 0x255450, win 0x15c350;
|
||||
void onRefresh(cocos2d::CCObject* sender) = mac 0x253090;
|
||||
void onInfo(cocos2d::CCObject* sender) = mac 0x253170, win 0x15cb00;
|
||||
void onNew(cocos2d::CCObject* sender) = win 0x15cbf0, mac 0x252ac0;
|
||||
static LevelBrowserLayer* create(GJSearchObject* search) = mac 0x251210, win 0x159fa0, ios 0x2d0a00;
|
||||
|
||||
PAD = win 0x4, mac 0x8;
|
||||
|
@ -4162,16 +4180,17 @@ class LevelEditorLayer : GJBaseGameLayer, LevelSettingsDelegate {
|
|||
class LevelInfoLayer : cocos2d::CCLayer, LevelDownloadDelegate, LevelUpdateDelegate, RateLevelDelegate, LikeItemDelegate, FLAlertLayerProtocol, LevelDeleteDelegate, NumberInputDelegate, SetIDPopupDelegate {
|
||||
static LevelInfoLayer* create(GJGameLevel* level) = mac 0x15f290, win 0x175d50;
|
||||
bool init(GJGameLevel* level) = win 0x175df0, mac 0x15f520;
|
||||
void onGarage(cocos2d::CCObject* sender) = win 0x177c10;
|
||||
void onGarage(cocos2d::CCObject* sender) = win 0x177c10, mac 0x163ac0;
|
||||
void onViewProfile(cocos2d::CCObject* sender) = mac 0x1617d0, win 0x17ac90;
|
||||
void onLevelInfo(cocos2d::CCObject* sender) = mac 0x163880, win 0x17acf0;
|
||||
void setupProgressBars() = win 0x177fc0;
|
||||
void setupProgressBars() = win 0x177fc0, mac 0x1627e0;
|
||||
void setupLevelInfo() = mac 0x161C80, win 0x178680;
|
||||
void downloadLevel() = win 0x177d90;
|
||||
void downloadLevel() = win 0x177d90, mac 0x161b90;
|
||||
void onPlay(cocos2d::CCObject* sender) = mac 0x161840, win 0x179730;
|
||||
virtual void levelDownloadFinished(GJGameLevel*) = mac 0x164C00, win 0x1790C0;
|
||||
virtual void levelUpdateFinished(GJGameLevel*, UpdateResponse) = mac 0x164E60, win 0x1792B0;
|
||||
void showUpdateAlert(UpdateResponse) = mac 0x164ED0, win 0x179300;
|
||||
void updateLabelValues() = mac 0x164090, win 0x17b170;
|
||||
|
||||
PAD = win 0x4, mac 0x8;
|
||||
cocos2d::CCMenu* m_playBtnMenu;
|
||||
|
@ -4181,13 +4200,13 @@ class LevelInfoLayer : cocos2d::CCLayer, LevelDownloadDelegate, LevelUpdateDeleg
|
|||
CCMenuItemSpriteExtra* m_starRateBtn;
|
||||
CCMenuItemSpriteExtra* m_demonRateBtn;
|
||||
PAD = win 0x4, mac 0x8;
|
||||
CCMenuItemToggler* m_toggler;
|
||||
cocos2d::CCLabelBMFont* m_label0;
|
||||
cocos2d::CCLabelBMFont* m_label1;
|
||||
cocos2d::CCLabelBMFont* m_label2;
|
||||
cocos2d::CCLabelBMFont* m_label3;
|
||||
cocos2d::CCLabelBMFont* m_label4;
|
||||
cocos2d::CCLabelBMFont* m_label5;
|
||||
CCMenuItemToggler* m_ldmToggler;
|
||||
cocos2d::CCLabelBMFont* m_ldmLabel;
|
||||
cocos2d::CCLabelBMFont* m_lengthLabel;
|
||||
cocos2d::CCLabelBMFont* m_downloadsLabel;
|
||||
cocos2d::CCLabelBMFont* m_likesLabel;
|
||||
cocos2d::CCLabelBMFont* m_orbsLabel;
|
||||
cocos2d::CCLabelBMFont* m_folderLabel;
|
||||
CCMenuItemSpriteExtra* m_cloneBtn;
|
||||
PAD = win 0x4, mac 0x8;
|
||||
}
|
||||
|
@ -4245,6 +4264,25 @@ class LevelSettingsDelegate {
|
|||
virtual void levelSettingsUpdated() {}
|
||||
}
|
||||
|
||||
class SecretLayer2 : cocos2d::CCLayer, TextInputDelegate, FLAlertLayerProtocol, DialogDelegate {
|
||||
static SecretLayer2* create() = win 0x21FD70;
|
||||
|
||||
bool init() = win 0x21FE10, mac 0x25fe70;
|
||||
bool onSubmit(cocos2d::CCObject*) = win 0x221ac0, mac 0x2611a0;
|
||||
void updateSearchLabel(const char* text) = win 0x222FC0, mac 0x260e10;
|
||||
void showCompletedLevel() = win 0x220C10;
|
||||
}
|
||||
|
||||
[[link(android)]]
|
||||
class SecretLayer2 : cocos2d::CCLayer, TextInputDelegate, FLAlertLayerProtocol, DialogDelegate {
|
||||
static SecretLayer2* create() = win 0x21FD70;
|
||||
|
||||
bool init() = win 0x21FE10, mac 0x25fe70;
|
||||
bool onSubmit(cocos2d::CCObject*) = win 0x221ac0, mac 0x2611a0;
|
||||
void updateSearchLabel(const char* text) = win 0x222FC0, mac 0x260e10;
|
||||
void showCompletedLevel() = win 0x220C10;
|
||||
}
|
||||
|
||||
[[link(android)]]
|
||||
class SecretLayer4 : cocos2d::CCLayer, TextInputDelegate, FLAlertLayerProtocol, DialogDelegate {
|
||||
static SecretLayer4* create() = mac 0x1ed500;
|
||||
|
@ -4428,7 +4466,6 @@ class LocalLevelManager : GManager {
|
|||
|
||||
cocos2d::CCDictionary* getAllLevelsInDict() = mac 0x35e3d0, win 0x18d7c0;
|
||||
|
||||
PAD = mac 0x4, win 0x1C;
|
||||
cocos2d::CCDictionary* m_loadData;
|
||||
cocos2d::CCDictionary* m_levelData;
|
||||
cocos2d::CCArray* m_localLevels;
|
||||
|
@ -4658,11 +4695,14 @@ class PauseLayer : CCBlockLayer {
|
|||
void createToggleButton(gd::string caption, cocos2d::SEL_MenuHandler callback, bool on, cocos2d::CCMenu* menu, cocos2d::CCPoint pos) = mac 0x20c890, win 0x1e5570;
|
||||
virtual void customSetup() = mac 0x20b300, win 0x1e4620;
|
||||
|
||||
void onRestart(cocos2d::CCObject* sender) = win 0x1e6040;
|
||||
void onRestart(cocos2d::CCObject* sender) = mac 0x20c860, win 0x1e6040;
|
||||
void onPracticeMode(cocos2d::CCObject* sender) = mac 0x20c6d0, win 0x1e5f30;
|
||||
void onNormalMode(cocos2d::CCObject* sender) = mac 0x20c720, win 0x1e5f60;
|
||||
void onResume(cocos2d::CCObject* sender) = mac 0x20c760, win 0x1e5fa0;
|
||||
virtual void keyDown(cocos2d::enumKeyCodes) = mac 0x20cc80, win 0x1E6580;
|
||||
|
||||
void musicSliderChanged(cocos2d::CCObject* sender) = win 0x1e5ce0;
|
||||
void sfxSliderChanged(cocos2d::CCObject* sender) = win 0x1ddfa0;
|
||||
void musicSliderChanged(cocos2d::CCObject* sender) = win 0x1e5ce0, mac 0x20cb00;
|
||||
void sfxSliderChanged(cocos2d::CCObject* sender) = win 0x1ddfa0, mac 0x20cb40;
|
||||
|
||||
bool m_unknown;
|
||||
bool m_unknown2;
|
||||
|
@ -4817,7 +4857,7 @@ class PlayLayer : GJBaseGameLayer, CCCircleWaveDelegate, CurrencyRewardDelegate,
|
|||
void spawnFirework() = mac 0x74200;
|
||||
void spawnParticle(char const*, int, cocos2d::tCCPositionType, cocos2d::CCPoint) = mac 0x76330;
|
||||
void spawnPlayer2() = mac 0x7d170, win 0x2089e0;
|
||||
void startGame() = mac 0x726b0;
|
||||
void startGame() = mac 0x726b0, win 0x1fd390;
|
||||
void startMusic() = mac 0x72910, win 0x20C8F0;
|
||||
void startRecording() = mac 0x7fec0;
|
||||
void startRecordingDelayed() = mac 0x7fed0;
|
||||
|
@ -4833,7 +4873,7 @@ class PlayLayer : GJBaseGameLayer, CCCircleWaveDelegate, CurrencyRewardDelegate,
|
|||
void toggleBGEffectVisibility(bool) = mac 0x7fe80;
|
||||
void toggleDualMode(GameObject*, bool, PlayerObject*, bool) = mac 0x7bf90, win 0x208880;
|
||||
void toggleFlipped(bool, bool) = mac 0x7bdc0, win 0x20ab20;
|
||||
void toggleGhostEffect(int) = mac 0x7fe40;
|
||||
void toggleGhostEffect(int) = mac 0x7fe40, win 0x1f8930;
|
||||
void toggleGlitter(bool) = mac 0x70e00, win 0x20a0d0;
|
||||
void togglePracticeMode(bool) = mac 0x7f9e0, win 0x20d0d0;
|
||||
void toggleProgressbar() = mac 0x6eeb0, win 0x208160;
|
||||
|
@ -5447,6 +5487,9 @@ class SetGroupIDLayer : FLAlertLayer, TextInputDelegate {
|
|||
void updateZOrder() = win 0x22e3d0;
|
||||
void onAddGroup(cocos2d::CCObject* sender) = mac 0x1967d0, win 0x22de20;
|
||||
void onClose(cocos2d::CCObject* sender) = mac 0x1966a0, win 0x22e830;
|
||||
void onEditorLayer(cocos2d::CCObject* sender) = win 0x22d690, mac 0x196800;
|
||||
void onEditorLayer2(cocos2d::CCObject* sender) = win 0x22d710, mac 0x196a40;
|
||||
void onZOrder(cocos2d::CCObject* sender) = win 0x22de80, mac 0x196920;
|
||||
|
||||
GameObject* m_targetObject;
|
||||
cocos2d::CCArray* m_targetObjects;
|
||||
|
@ -5571,12 +5614,14 @@ class SetupOpacityPopup : FLAlertLayer {
|
|||
[[link(android)]]
|
||||
class SetupPickupTriggerPopup : FLAlertLayer {
|
||||
static SetupPickupTriggerPopup* create(EffectGameObject*, cocos2d::CCArray*) = mac 0x35e70, win 0x23d4a0;
|
||||
bool init(EffectGameObject* obj, cocos2d::CCArray* arr) = win 0x23d550, mac 0x36070;
|
||||
void onItemIDArrow(cocos2d::CCObject*) = mac 0x37100;
|
||||
void onNextItemID(cocos2d::CCObject*) = mac 0x37260;
|
||||
void textChanged(CCTextInputNode*) = mac 0x37ca0;
|
||||
void updateItemID() = mac 0x37ab0, win 0x23e4f0;
|
||||
|
||||
PAD = win 0xc;
|
||||
PAD = win 0xc, mac 0x18;
|
||||
CCTextInputNode* m_itemIDInput;
|
||||
CCTextInputNode* m_countInput;
|
||||
}
|
||||
|
||||
|
@ -5658,9 +5703,9 @@ class SimplePlayer : cocos2d::CCSprite {
|
|||
static SimplePlayer* create(int iconID) = mac 0x1b6140, win 0x12bd80;
|
||||
void updatePlayerFrame(int iconID, IconType iconType) = mac 0x1b62f0, win 0x12c650;
|
||||
void updateColors() = mac 0x1ba1f0, win 0x12c440, ios 0x224f2c;
|
||||
void setFrames(const char* firstLayer, const char* secondLayer, const char* birdDome, const char* outlineSprite, const char* detailSprite) = win 0x12c9e0;
|
||||
void setFrames(const char* firstLayer, const char* secondLayer, const char* birdDome, const char* outlineSprite, const char* detailSprite) = mac 0x1bca10, win 0x12c9e0;
|
||||
virtual void setColor(const cocos2d::ccColor3B& color) = mac 0x1bc9b0, win 0x12c410;
|
||||
virtual void setOpacity(unsigned char opacity) = win 0x12cb90;
|
||||
virtual void setOpacity(unsigned char opacity) = mac 0x135370, win 0x12cb90;
|
||||
|
||||
cocos2d::CCSprite* m_firstLayer;
|
||||
cocos2d::CCSprite* m_secondLayer;
|
||||
|
@ -5692,7 +5737,7 @@ class Slider : cocos2d::CCLayer {
|
|||
SliderTouchLogic* m_touchLogic;
|
||||
cocos2d::CCSprite* m_sliderBar;
|
||||
cocos2d::CCSprite* m_groove;
|
||||
float m_unknown;
|
||||
float m_width;
|
||||
float m_height;
|
||||
}
|
||||
|
||||
|
@ -5776,6 +5821,8 @@ class SpeedObject : cocos2d::CCNode {
|
|||
float m_somethingToCompare;
|
||||
float m_idk3;
|
||||
float m_idk4;
|
||||
|
||||
static SpeedObject* create(GameObject*, int, float) = win 0x20DE70;
|
||||
}
|
||||
|
||||
[[link(android)]]
|
||||
|
@ -5991,7 +6038,7 @@ class UILayer : cocos2d::CCLayerColor {
|
|||
virtual void keyDown(cocos2d::enumKeyCodes key) = mac 0x280470, win 0x25f890;
|
||||
virtual void keyUp(cocos2d::enumKeyCodes key) = mac 0x280600, win 0x25fa10;
|
||||
UILayer() = win 0x25f230;
|
||||
~UILayer() = win 0x25fef0;
|
||||
~UILayer() = win 0x25fef0, mac 0x280c90;
|
||||
|
||||
PAD = mac 0x16, win 0x8, android 0x8;
|
||||
cocos2d::CCMenu* m_checkPointMenu;
|
||||
|
|
13
loader/include/Geode/cocos/base_nodes/CCNode.h
vendored
13
loader/include/Geode/cocos/base_nodes/CCNode.h
vendored
|
@ -700,12 +700,6 @@ public:
|
|||
* @param cleanup true if all running actions and callbacks on the child node will be cleanup, false otherwise.
|
||||
*/
|
||||
virtual void removeChildByTag(int tag, bool cleanup);
|
||||
/**
|
||||
* Removes a child from the container by its ID.
|
||||
* @param id The ID of the node
|
||||
* @note Geode addition
|
||||
*/
|
||||
void removeChildByID(std::string const& id);
|
||||
/**
|
||||
* Removes all children from the container with a cleanup.
|
||||
*
|
||||
|
@ -890,6 +884,13 @@ public:
|
|||
*/
|
||||
GEODE_DLL CCNode* getChildByIDRecursive(std::string const& id);
|
||||
|
||||
/**
|
||||
* Removes a child from the container by its ID.
|
||||
* @param id The ID of the node
|
||||
* @note Geode addition
|
||||
*/
|
||||
GEODE_DLL void removeChildByID(std::string const& id);
|
||||
|
||||
/**
|
||||
* Add a child before a specified existing child
|
||||
* @param child The node to add. The node may not be a child of another
|
||||
|
|
|
@ -90,6 +90,7 @@ protected:
|
|||
bool m_bIsSendCleanupToScene;
|
||||
|
||||
public:
|
||||
GEODE_CUSTOM_CONSTRUCTOR_COCOS(CCTransitionScene, CCScene)
|
||||
/**
|
||||
* @js ctor
|
||||
*/
|
||||
|
@ -147,6 +148,7 @@ public:
|
|||
* @js ctor
|
||||
*/
|
||||
CCTransitionSceneOriented();
|
||||
GEODE_CUSTOM_CONSTRUCTOR_COCOS(CCTransitionSceneOriented, CCTransitionScene)
|
||||
/**
|
||||
* @js NA
|
||||
* @lua NA
|
||||
|
@ -171,6 +173,7 @@ public:
|
|||
* @js ctor
|
||||
*/
|
||||
CCTransitionRotoZoom();
|
||||
GEODE_CUSTOM_CONSTRUCTOR_COCOS(CCTransitionRotoZoom, CCTransitionScene)
|
||||
/**
|
||||
* @js NA
|
||||
* @lua NA
|
||||
|
@ -623,6 +626,7 @@ public:
|
|||
* @js ctor
|
||||
*/
|
||||
CCTransitionFade();
|
||||
GEODE_CUSTOM_CONSTRUCTOR_COCOS(CCTransitionFade, CCTransitionScene)
|
||||
/**
|
||||
* @js NA
|
||||
* @lua NA
|
||||
|
|
2
loader/include/Geode/fmod/fmod.h
vendored
2
loader/include/Geode/fmod/fmod.h
vendored
|
@ -31,7 +31,7 @@ FMOD_RESULT F_API FMOD_File_GetDiskBusy (int *busy);
|
|||
/*
|
||||
FMOD System factory functions. Use this to create an FMOD System Instance. below you will see FMOD_System_Init/Close to get started.
|
||||
*/
|
||||
FMOD_RESULT F_API FMOD_System_Create (FMOD_SYSTEM **system);
|
||||
FMOD_RESULT /*F_API*/ FMOD_System_Create (FMOD_SYSTEM **system);
|
||||
FMOD_RESULT F_API FMOD_System_Release (FMOD_SYSTEM *system);
|
||||
|
||||
/*
|
||||
|
|
|
@ -96,6 +96,11 @@ namespace geode {
|
|||
*/
|
||||
std::optional<std::string> match;
|
||||
|
||||
/**
|
||||
* The CCTextInputNode's allowed character filter
|
||||
*/
|
||||
std::optional<std::string> filter;
|
||||
|
||||
static Result<StringSetting> parse(JsonMaybeObject& obj);
|
||||
};
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
namespace geode::modifier {
|
||||
template <uint32_t Id>
|
||||
uintptr_t address();
|
||||
GEODE_HIDDEN uintptr_t address();
|
||||
|
||||
Result<tulip::hook::HandlerMetadata> handlerMetadataForAddress(uintptr_t address);
|
||||
}
|
||||
|
|
|
@ -953,7 +953,7 @@ namespace geode::cocos {
|
|||
return m_arr ? m_arr->count() : 0;
|
||||
}
|
||||
|
||||
T operator[](size_t index) {
|
||||
T* operator[](size_t index) {
|
||||
return static_cast<T*>(m_arr->objectAtIndex(index));
|
||||
}
|
||||
|
||||
|
|
|
@ -7,8 +7,11 @@
|
|||
using namespace geode::prelude;
|
||||
|
||||
$register_ids(GJGarageLayer) {
|
||||
// the lock does not exist for not logged in users
|
||||
auto loggedInOffset = GJAccountManager::get()->m_accountID == GJAccountManager::get()->m_playerID ? -1 : 0;
|
||||
|
||||
setIDSafe(this, 2, "username-label");
|
||||
setIDSafe(this, 6, "player-icon");
|
||||
setIDSafe(this, 6 + loggedInOffset, "player-icon");
|
||||
|
||||
auto winSize = CCDirector::get()->getWinSize();
|
||||
|
||||
|
@ -39,7 +42,7 @@ $register_ids(GJGarageLayer) {
|
|||
|
||||
setIDs(
|
||||
this,
|
||||
10,
|
||||
10 + loggedInOffset,
|
||||
"cube-selection-menu",
|
||||
"ship-selection-menu",
|
||||
"ball-selection-menu",
|
||||
|
|
|
@ -62,6 +62,7 @@ Result<StringSetting> StringSetting::parse(JsonMaybeObject& obj) {
|
|||
StringSetting sett;
|
||||
parseCommon(sett, obj);
|
||||
obj.has("match").into(sett.match);
|
||||
obj.has("filter").into(sett.filter);
|
||||
return Ok(sett);
|
||||
}
|
||||
|
||||
|
|
|
@ -113,7 +113,7 @@ CCArray* InstallListPopup::createCells(std::unordered_map<std::string, InstallLi
|
|||
|
||||
// installed
|
||||
// TODO: we should be able to select a different version even if its installed
|
||||
if (/*item.mod && !item.mod->isUninstalled()*/item.mod->getMetadata().getID() == "geode.loader") {
|
||||
if (item.mod && /*!item.mod->isUninstalled()*/item.mod->getMetadata().getID() == "geode.loader") {
|
||||
bottom.push_back(ModInstallListCell::create(item.mod, this, this->getCellSize()));
|
||||
for (auto const& dep : item.mod->getMetadata().getDependencies()) {
|
||||
queue.push(dep);
|
||||
|
|
|
@ -324,6 +324,11 @@ bool StringSettingNode::setup(StringSettingValue* setting, float width) {
|
|||
m_input = InputNode::create(width / 2 - 10.f, "Text", "chatFont.fnt");
|
||||
m_input->setPosition({ -(width / 2 - 70.f) / 2, .0f });
|
||||
m_input->setScale(.65f);
|
||||
|
||||
if (setting->castDefinition().filter.has_value()) {
|
||||
m_input->getInput()->setAllowedChars(setting->castDefinition().filter.value());
|
||||
}
|
||||
|
||||
m_input->getInput()->setDelegate(this);
|
||||
m_menu->addChild(m_input);
|
||||
|
||||
|
|
|
@ -109,8 +109,8 @@ bool MDTextArea::init(std::string const& str, CCSize const& size) {
|
|||
if (!CCLayer::init()) return false;
|
||||
|
||||
m_text = str;
|
||||
m_size = size;
|
||||
this->setContentSize(size);
|
||||
m_size = size - CCSize { 15.f, 0.f };
|
||||
this->setContentSize(m_size);
|
||||
m_renderer = TextRenderer::create();
|
||||
CC_SAFE_RETAIN(m_renderer);
|
||||
|
||||
|
@ -118,8 +118,8 @@ bool MDTextArea::init(std::string const& str, CCSize const& size) {
|
|||
m_bgSprite->setScale(.5f);
|
||||
m_bgSprite->setColor({ 0, 0, 0 });
|
||||
m_bgSprite->setOpacity(75);
|
||||
m_bgSprite->setContentSize(size * 2 + CCSize { 25.f, 25.f });
|
||||
m_bgSprite->setPosition(size / 2);
|
||||
m_bgSprite->setContentSize(size * 2);
|
||||
m_bgSprite->setPosition(m_size / 2);
|
||||
this->addChild(m_bgSprite);
|
||||
|
||||
m_scrollLayer = ScrollLayer::create({ 0, 0, m_size.width, m_size.height }, true);
|
||||
|
@ -695,7 +695,16 @@ void MDTextArea::updateLabel() {
|
|||
|
||||
m_renderer->end();
|
||||
|
||||
m_scrollLayer->m_contentLayer->setContentSize(m_content->getContentSize());
|
||||
if (m_content->getContentSize().height > m_size.height) {
|
||||
// Generate bottom padding
|
||||
m_scrollLayer->m_contentLayer->setContentSize(m_content->getContentSize() + CCSize { 0.f, 12.5 });
|
||||
m_content->setPositionY(10.f);
|
||||
} else {
|
||||
m_scrollLayer->m_contentLayer->setContentSize(m_content->getContentSize());
|
||||
m_content->setPositionY(-2.5f);
|
||||
}
|
||||
|
||||
|
||||
m_scrollLayer->moveToTop();
|
||||
}
|
||||
|
||||
|
|
|
@ -79,6 +79,7 @@ Result<ByteVector> web::fetchBytes(std::string const& url) {
|
|||
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, 0);
|
||||
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, 0);
|
||||
curl_easy_setopt(curl, CURLOPT_WRITEDATA, &ret);
|
||||
curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1);
|
||||
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, utils::fetch::writeBytes);
|
||||
auto res = curl_easy_perform(curl);
|
||||
if (res != CURLE_OK) {
|
||||
|
@ -118,6 +119,7 @@ Result<std::string> web::fetch(std::string const& url) {
|
|||
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, 0);
|
||||
curl_easy_setopt(curl, CURLOPT_WRITEDATA, &ret);
|
||||
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, utils::fetch::writeString);
|
||||
curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1);
|
||||
auto res = curl_easy_perform(curl);
|
||||
if (res != CURLE_OK) {
|
||||
curl_easy_cleanup(curl);
|
||||
|
|
Loading…
Reference in a new issue