/data/Tupfile.lua |
---|
67,7 → 67,7 |
{"SETTINGS/NETWORK.INI", "common/settings/network.ini"}, |
{"SETTINGS/SYSTEM.INI", "common/settings/system.ini"}, |
{"SETTINGS/TASKBAR.INI", "common/settings/taskbar.ini"}, |
{"SETTINGS/WEATHER.JSON", PROGS .. "/other/Weather/weather.json"}, |
{"SETTINGS/weather.json", PROGS .. "/other/Weather/weather.json"}, |
} |
-- For russian build, add russian-only files. |
/programs/develop/tinypad/trunk/tp-common.asm |
---|
1,5 → 1,5 |
diff16 'tp-common.asm',0,$ |
include '../../../debug.inc' |
;----------------------------------------------------------------------------- |
proc clear_selection ;//////////////////////////////////////////////////////// |
;----------------------------------------------------------------------------- |
71,6 → 71,8 |
proc get_real_length ;//////////////////////////////////////////////////////// |
;----------------------------------------------------------------------------- |
mov eax,[esi+EDITOR_LINE_DATA.Size] |
debug_print_dec eax |
debug_print "|" |
@@: cmp byte[esi+eax+sizeof.EDITOR_LINE_DATA-1],' ' |
jne @f |
dec eax |
/programs/other/Weather/weather.c |
---|
45,6 → 45,7 |
#define IMAGE_URL "openweathermap.org/img/w/%s.png" |
Image *blend=NULL; |
const char *config_name = "/sys/Settings/weather.json"; |
unsigned char char_size=1; |
uint64_t AutoUpdateTime = 0; |
228,12 → 229,12 |
void get_config(char **City, char **Token, char **Units) // Загружаем конфиг |
{ |
FILE *config_j = fopen("/sys/Settings/weather.json", "rb"); |
FILE *config_j = fopen(config_name, "rb"); |
if(config_j==NULL){ |
notify_show("'Configuration file not found!' -E"); |
exit(0); |
} |
size_t size = _ksys_get_filesize("weather.json"); // Получаем размер файла |
size_t size = _ksys_get_filesize((char*)config_name); // Получаем размер файла |
char *config_buff = safe_malloc(size+1); |
if(size != fread(config_buff, sizeof(char), size, config_j)){ |
notify_show("'The configuration file was not fully read!' -E"); |