mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-03-30 08:42:16 +00:00
Organize headers
This commit is contained in:
parent
eddc862fa3
commit
0f666de5e6
@ -2,7 +2,9 @@
|
|||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include <cxx.h>
|
|
||||||
|
#include "core-rs.hpp"
|
||||||
|
#include "resetprop/resetprop.hpp"
|
||||||
|
|
||||||
extern bool RECOVERY_MODE;
|
extern bool RECOVERY_MODE;
|
||||||
extern std::atomic<ino_t> pkg_xml_ino;
|
extern std::atomic<ino_t> pkg_xml_ino;
|
||||||
@ -27,10 +29,3 @@ void install_apk(const char *apk);
|
|||||||
void uninstall_pkg(const char *pkg);
|
void uninstall_pkg(const char *pkg);
|
||||||
void clear_pkg(const char *pkg, int user_id);
|
void clear_pkg(const char *pkg, int user_id);
|
||||||
[[noreturn]] void install_module(const char *file);
|
[[noreturn]] void install_module(const char *file);
|
||||||
|
|
||||||
// System properties
|
|
||||||
rust::String get_prop_rs(const char *name, bool persist);
|
|
||||||
std::string get_prop(const char *name, bool persist = false);
|
|
||||||
int delete_prop(const char *name, bool persist = false);
|
|
||||||
int set_prop(const char *name, const char *value, bool skip_svc = false);
|
|
||||||
void load_prop_file(const char *filename, bool skip_svc = false);
|
|
||||||
|
@ -9,7 +9,7 @@ mod logging;
|
|||||||
#[cxx::bridge]
|
#[cxx::bridge]
|
||||||
pub mod ffi {
|
pub mod ffi {
|
||||||
extern "C++" {
|
extern "C++" {
|
||||||
include!("core.hpp");
|
include!("resetprop/resetprop.hpp");
|
||||||
unsafe fn get_prop_rs(name: *const c_char, persist: bool) -> String;
|
unsafe fn get_prop_rs(name: *const c_char, persist: bool) -> String;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,7 +5,6 @@
|
|||||||
|
|
||||||
#include <base.hpp>
|
#include <base.hpp>
|
||||||
|
|
||||||
#include "../core.hpp"
|
|
||||||
#include "resetprop.hpp"
|
#include "resetprop.hpp"
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <map>
|
#include <map>
|
||||||
|
#include <cxx.h>
|
||||||
|
|
||||||
#define _REALLY_INCLUDE_SYS__SYSTEM_PROPERTIES_H_
|
#define _REALLY_INCLUDE_SYS__SYSTEM_PROPERTIES_H_
|
||||||
#include <api/_system_properties.h>
|
#include <api/_system_properties.h>
|
||||||
@ -21,6 +22,13 @@ private:
|
|||||||
prop_list &list;
|
prop_list &list;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// System properties
|
||||||
|
rust::String get_prop_rs(const char *name, bool persist);
|
||||||
|
std::string get_prop(const char *name, bool persist = false);
|
||||||
|
int delete_prop(const char *name, bool persist = false);
|
||||||
|
int set_prop(const char *name, const char *value, bool skip_svc = false);
|
||||||
|
void load_prop_file(const char *filename, bool skip_svc = false);
|
||||||
|
|
||||||
void persist_get_prop(const char *name, prop_cb *prop_cb);
|
void persist_get_prop(const char *name, prop_cb *prop_cb);
|
||||||
void persist_get_props(prop_cb *prop_cb);
|
void persist_get_props(prop_cb *prop_cb);
|
||||||
bool persist_delete_prop(const char *name);
|
bool persist_delete_prop(const char *name);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user