mirror of
https://github.com/geode-sdk/geode.git
synced 2024-11-14 19:15:05 -05:00
Merge branch 'main' into settings
This commit is contained in:
commit
78c69199e0
4 changed files with 112 additions and 3 deletions
94
CODE_OF_CONDUCT.md
Normal file
94
CODE_OF_CONDUCT.md
Normal file
|
@ -0,0 +1,94 @@
|
|||
|
||||
# Code of Conduct
|
||||
|
||||
## Notes
|
||||
|
||||
As an open source project, our policies are based on a Code of Conduct. Please
|
||||
make sure you read it before using our services. We expect everyone to follow
|
||||
the guidelines presented in this document.
|
||||
|
||||
## Our Pledge
|
||||
|
||||
We as members, contributors, and leaders pledge to make participation in our
|
||||
community a harassment-free experience for everyone, regardless of age, body
|
||||
size, visible or invisible disability, ethnicity, sex characteristics, gender
|
||||
identity and expression, level of experience, education, socio-economic status,
|
||||
nationality, personal appearance, race, caste, color, religion, or sexual
|
||||
identity and orientation.
|
||||
|
||||
We pledge to act and interact in ways that contribute to an open, welcoming,
|
||||
diverse, inclusive, and healthy community.
|
||||
|
||||
## Our Standards
|
||||
|
||||
Examples of behavior that contributes to a positive environment for our
|
||||
community include:
|
||||
|
||||
* Demonstrating empathy and kindness toward other people
|
||||
* Being respectful of differing opinions, viewpoints, and experiences
|
||||
* Giving and gracefully accepting constructive feedback
|
||||
* Accepting responsibility and apologizing to those affected by our mistakes,
|
||||
and learning from the experience
|
||||
* Focusing on what is best not just for us as individuals, but for the overall
|
||||
community
|
||||
|
||||
Examples of unacceptable behavior include:
|
||||
|
||||
* The use of sexualized language or imagery, and sexual attention or advances of
|
||||
any kind
|
||||
* Trolling (antagonistic, inflammatory, insincere behaviour), insulting or
|
||||
derogatory comments, and personal or political attacks
|
||||
* Threats of violence or violent acts towards others
|
||||
* Public or private harassment
|
||||
* Intentionally dead-naming or misgendering others
|
||||
* Publishing others' private information, such as a physical or email address,
|
||||
without their explicit permission
|
||||
* Gatekeeping others' access to mental health or accessibility tools
|
||||
* Other conduct which could reasonably be considered inappropriate in a
|
||||
professional setting
|
||||
|
||||
## Enforcement Responsibilities
|
||||
|
||||
Community leaders are responsible for clarifying and enforcing our standards of
|
||||
acceptable behavior and will take appropriate and fair corrective action in
|
||||
response to any behavior that they deem inappropriate, threatening, offensive,
|
||||
or harmful. Actions may range from a warning to permanent removal from the
|
||||
community.
|
||||
|
||||
Community leaders have the right and responsibility to remove, edit, or reject
|
||||
comments, commits, code, wiki edits, issues, and other contributions that are
|
||||
not aligned to this Code of Conduct, and will communicate reasons for moderation
|
||||
decisions when appropriate.
|
||||
|
||||
## Scope
|
||||
|
||||
This Code of Conduct applies within all community spaces, and also applies when
|
||||
an individual is officially representing the community in public spaces.
|
||||
Examples of representing our community include using an official email address,
|
||||
posting via an official social media account, or acting as an appointed
|
||||
representative at an online or offline event.
|
||||
|
||||
## Enforcement
|
||||
|
||||
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
||||
reported to the community leaders directly on Discord, or via a private message
|
||||
to the official Geode X account ([@GeodeSDK](https://x.com/GeodeSDK)). If your report concerns a specific
|
||||
community team member or group of community team members, please send your
|
||||
report to a team member that is not part of the report, or a member of the
|
||||
administrative board.
|
||||
|
||||
All complaints will be reviewed and investigated promptly and fairly. All
|
||||
community leaders are obligated to respect the privacy and security of the
|
||||
reporter of any incident.
|
||||
|
||||
## Changes & Feedback
|
||||
|
||||
Since the world is a dynamic place, this Code of Conduct may need changes. We
|
||||
reserve the right to update this Code of Conduct at any time.
|
||||
|
||||
We welcome feedback and suggestions. Feel free to open an issue on our
|
||||
[GitHub](https://github.com/geode-sdk/geode).
|
||||
|
||||
## Attribution
|
||||
|
||||
This Code of Conduct is adapted from the [Contributor Covenant version 2.1](https://www.contributor-covenant.org/version/2/1/code_of_conduct.html), with inspirations taken from [Prism Launcher Code of Conduct](https://prismlauncher.org/wiki/overview/code-of-conduct/) and [QuiltMC Code of Conduct](https://quiltmc.org/en/community/code-of-conduct/).
|
4
loader/include/Geode/cocos/cocoa/CCArray.h
vendored
4
loader/include/Geode/cocos/cocoa/CCArray.h
vendored
|
@ -186,7 +186,7 @@ public:
|
|||
* Returns first element, or null if empty
|
||||
* @note Geode addition
|
||||
*/
|
||||
CCObject* firstObject();
|
||||
GEODE_DLL CCObject* firstObject();
|
||||
/** Returns last element */
|
||||
CCObject* lastObject();
|
||||
/** Returns a random element */
|
||||
|
@ -215,7 +215,7 @@ public:
|
|||
* Remove first object, or do nothing if array is empty
|
||||
* @note Geode addition
|
||||
*/
|
||||
void removeFirstObject(bool bReleaseObj = true);
|
||||
GEODE_DLL void removeFirstObject(bool bReleaseObj = true);
|
||||
/** Remove last object */
|
||||
void removeLastObject(bool bReleaseObj = true);
|
||||
/** Remove a certain object */
|
||||
|
|
|
@ -113,7 +113,6 @@ namespace geode::utils::web {
|
|||
class Impl;
|
||||
|
||||
std::shared_ptr<Impl> m_impl;
|
||||
|
||||
public:
|
||||
WebRequest();
|
||||
~WebRequest();
|
||||
|
@ -253,6 +252,13 @@ namespace geode::utils::web {
|
|||
*/
|
||||
WebRequest& bodyJSON(matjson::Value const& json);
|
||||
|
||||
/**
|
||||
* Gets the unique request ID
|
||||
*
|
||||
* @return size_t
|
||||
*/
|
||||
size_t getID() const;
|
||||
|
||||
|
||||
/**
|
||||
* Gets the request method as a string
|
||||
|
|
|
@ -188,6 +188,8 @@ std::optional<float> WebProgress::uploadProgress() const {
|
|||
|
||||
class WebRequest::Impl {
|
||||
public:
|
||||
static std::atomic_size_t s_counter;
|
||||
|
||||
std::string m_method;
|
||||
std::string m_url;
|
||||
std::unordered_map<std::string, std::string> m_headers;
|
||||
|
@ -203,6 +205,9 @@ public:
|
|||
std::string m_CABundleContent;
|
||||
ProxyOpts m_proxyOpts = {};
|
||||
HttpVersion m_httpVersion = HttpVersion::DEFAULT;
|
||||
size_t m_id;
|
||||
|
||||
Impl() : m_id(s_counter++) {}
|
||||
|
||||
WebResponse makeError(int code, std::string const& msg) {
|
||||
auto res = WebResponse();
|
||||
|
@ -584,6 +589,10 @@ WebRequest& WebRequest::bodyJSON(matjson::Value const& json) {
|
|||
return *this;
|
||||
}
|
||||
|
||||
size_t WebRequest::getID() const {
|
||||
return m_impl->m_id;
|
||||
}
|
||||
|
||||
std::string WebRequest::getMethod() const {
|
||||
return m_impl->m_method;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue