Remove done

git-svn-id: svn://db.shs.com.ru/pip@119 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5
This commit is contained in:
2015-04-24 10:00:22 +00:00
parent 6ebe7e5ce6
commit 1295289a06
3 changed files with 18 additions and 11 deletions

View File

@@ -23,6 +23,7 @@
#include "pichar.h"
#ifdef PIP_ICU
# include "unicode/ucnv.h"
# include "unicode/ustring.h"
char * __syslocname__ = 0;
char * __sysoemname__ = 0;
#endif

View File

@@ -39,11 +39,17 @@
# include <utime.h>
#endif
#define S_IFHDN 0x40
#ifdef QNX
#if defined(QNX) || defined(ANDROID)
# define _fopen_call_ fopen
# define _fseek_call_ fseek
# define _ftell_call_ ftell
# define _stat_struct_ struct stat
# define _stat_call_ stat
# define _stat_link_ lstat
#else
# define _fopen_call_ fopen64
# define _fseek_call_ fseeko64
# define _ftell_call_ ftello64
# define _stat_struct_ struct stat64
# define _stat_call_ stat64
# define _stat_link_ lstat64
@@ -142,7 +148,7 @@ bool PIFile::openDevice() {
if (fd != 0) fclose(fd);
}
}
fd = fopen64(p.data(), strType(mode_).data());
fd = _fopen_call_(p.data(), strType(mode_).data());
opened_ = (fd != 0);
if (opened_) {
fdi = fileno(fd);
@@ -217,9 +223,9 @@ PIByteArray PIFile::readAll(bool forceRead) {
llong PIFile::size() const {
if (!opened_) return -1;
llong s, cp = pos();
fseeko64(fd, 0, SEEK_END); clearerr(fd);
_fseek_call_(fd, 0, SEEK_END); clearerr(fd);
s = pos();
fseeko64(fd, cp, SEEK_SET); clearerr(fd);
_fseek_call_(fd, cp, SEEK_SET); clearerr(fd);
return s;
}
@@ -244,7 +250,7 @@ void PIFile::resize(llong new_size, uchar fill_) {
bool PIFile::isExists(const PIString & path) {
FILE * f = fopen64(PIString(path).data(), "r");
FILE * f = _fopen_call_(PIString(path).data(), "r");
bool ok = (f != 0);
if (ok) fclose(f);
return ok;
@@ -288,21 +294,21 @@ void PIFile::flush() {
void PIFile::seek(llong position) {
if (!opened_) return;
fseeko64(fd, position, SEEK_SET);
_fseek_call_(fd, position, SEEK_SET);
clearerr(fd);
}
void PIFile::seekToBegin() {
if (!opened_) return;
fseeko64(fd, 0, SEEK_SET);
_fseek_call_(fd, 0, SEEK_SET);
clearerr(fd);
}
void PIFile::seekToEnd() {
if (!opened_) return;
fseeko64(fd, 0, SEEK_END);
_fseek_call_(fd, 0, SEEK_END);
clearerr(fd);
}
@@ -328,7 +334,7 @@ void PIFile::setPath(const PIString & path) {
llong PIFile::pos() const {
if (!opened_) return -1;
return ftello64(fd);
return _ftell_call_(fd);
}

View File

@@ -286,16 +286,16 @@ void Daemon::fillInfoTile(const Daemon::HostInfo & hi) {
void Daemon::tileEvent(PIScreenTile * t, TileEvent e) {
if (t == list_daemons) {
PIMutexLocker ml(remote_mutex);
if (e.type == TileList::RowPressed) {
PIMutexLocker ml(remote_mutex);
connectToDaemon(list_daemons->content[e.data.toInt()].first);
showActionList();
}
return;
}
if (t == list_actions) {
PIMutexLocker ml(remote_mutex);
if (e.type == TileList::RowPressed) {
PIMutexLocker ml(remote_mutex);
switch (e.data.toInt()) {
case 0: mode = 2; showTile(tile_info, "Information"); break;
case 1: