CtrlLib: Fixed several issues

git-svn-id: svn://ultimatepp.org/upp/trunk@13604 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2019-09-14 08:25:08 +00:00
parent 845b548fa2
commit de7ac87d76
2 changed files with 3 additions and 2 deletions

View file

@ -122,13 +122,13 @@ void FileList::Paint(Draw& w, const Rect& r, const Value& q,
Color ink, Color paper, dword style) const
{
const File& m = ValueTo<File>(q);
w.DrawRect(r, paper);
bool inv = ((style & Display::SELECT) || (style & Display::CURSOR)) && (style & Display::FOCUS);
w.DrawRect(r, inv ? SColorHighlight() : paper);
int x = r.left + 2;
w.DrawImage(x, r.top + (r.Height() - m.icon.GetSize().cy) / 2, m.icon);
x += iconwidth;
x += 2;
FontInfo fi = m.font.Info();
bool inv = (style & Display::SELECT) && (style & Display::FOCUS);
DrawFileName(w, x, r.top + (r.Height() - fi.GetHeight()) / 2,
r.right - x - 2, r.Height(), WString(m.name), m.isdir, m.font,
inv ? SColorHighlightText : m.ink,

View file

@ -1496,6 +1496,7 @@ void FileSel::FileUpdate() {
}
void FileSel::Rename(const String& on, const String& nn) {
#ifdef PLATFORM_WIN32
if(FileMove(FilePath(on), FilePath(nn)))
#else