add support for Apple Pencil and build for iOS
This commit is contained in:
@@ -3,6 +3,10 @@
|
||||
#include "node_panel_brush.h"
|
||||
#include "asset.h"
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <Foundation/Foundation.h>
|
||||
#endif
|
||||
|
||||
Node* NodeButtonBrush::clone_instantiate() const
|
||||
{
|
||||
return new NodeButtonBrush();
|
||||
@@ -99,9 +103,13 @@ std::vector<std::string> NodePanelBrush::FindAllBrushes(std::string folder)
|
||||
}
|
||||
AAssetDir_close(dir);
|
||||
#else
|
||||
NSString* bundle_path = [[NSBundle mainBundle] resourcePath];
|
||||
std::string base = [bundle_path cStringUsingEncoding:1];
|
||||
std::string abs_path = base + "/" + folder;
|
||||
|
||||
DIR *dp;
|
||||
struct dirent *ep;
|
||||
dp = opendir(folder.c_str());
|
||||
dp = opendir(abs_path.c_str());
|
||||
|
||||
if (dp != NULL)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user