summaryrefslogtreecommitdiff
path: root/RealtimeSync/functions.cpp
blob: 15461cc4ebb872138e989e4de92bb31835a249ee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// **************************************************************************
// * This file is part of the FreeFileSync project. It is distributed under *
// * GNU General Public License: http://www.gnu.org/licenses/gpl.html       *
// * Copyright (C) 2008-2010 ZenJu (zhnmju123 AT gmx.de)                    *
// **************************************************************************
//
#include "functions.h"
#include <wx/textctrl.h>
#include <wx/filepicker.h>
#include "../shared/stringConv.h"
#include "../shared/fileHandling.h"

using namespace FreeFileSync;

void RealtimeSync::setDirectoryName(const wxString& dirname, wxTextCtrl* txtCtrl, wxDirPickerCtrl* dirPicker)
{
    txtCtrl->SetValue(dirname);
    const Zstring leftDirFormatted = FreeFileSync::getFormattedDirectoryName(wxToZ(dirname));
    if (dirExists(leftDirFormatted))
        dirPicker->SetPath(zToWx(leftDirFormatted));
}

bgstack15