155 |
|
|
156 |
void LSCPServer::DbInstrumentsEventHandler::DirectoryNameChanged(String Dir, String NewName) { |
void LSCPServer::DbInstrumentsEventHandler::DirectoryNameChanged(String Dir, String NewName) { |
157 |
Dir = "'" + InstrumentsDb::toEscapedPath(Dir) + "'"; |
Dir = "'" + InstrumentsDb::toEscapedPath(Dir) + "'"; |
158 |
NewName = "'" + InstrumentsDb::toEscapedName(NewName) + "'"; |
NewName = "'" + InstrumentsDb::toEscapedPath(NewName) + "'"; |
159 |
LSCPServer::SendLSCPNotify(LSCPEvent(LSCPEvent::event_db_instr_dir_info, "NAME", Dir, NewName)); |
LSCPServer::SendLSCPNotify(LSCPEvent(LSCPEvent::event_db_instr_dir_info, "NAME", Dir, NewName)); |
160 |
} |
} |
161 |
|
|
169 |
|
|
170 |
void LSCPServer::DbInstrumentsEventHandler::InstrumentNameChanged(String Instr, String NewName) { |
void LSCPServer::DbInstrumentsEventHandler::InstrumentNameChanged(String Instr, String NewName) { |
171 |
Instr = "'" + InstrumentsDb::toEscapedPath(Instr) + "'"; |
Instr = "'" + InstrumentsDb::toEscapedPath(Instr) + "'"; |
172 |
NewName = "'" + InstrumentsDb::toEscapedName(NewName) + "'"; |
NewName = "'" + InstrumentsDb::toEscapedPath(NewName) + "'"; |
173 |
LSCPServer::SendLSCPNotify(LSCPEvent(LSCPEvent::event_db_instr_info, "NAME", Instr, NewName)); |
LSCPServer::SendLSCPNotify(LSCPEvent(LSCPEvent::event_db_instr_info, "NAME", Instr, NewName)); |
174 |
} |
} |
175 |
|
|
2354 |
|
|
2355 |
for (int i = 0; i < dirs->size(); i++) { |
for (int i = 0; i < dirs->size(); i++) { |
2356 |
if (list != "") list += ","; |
if (list != "") list += ","; |
2357 |
|
list += "'" + InstrumentsDb::toEscapedPath(dirs->at(i)) + "'"; |
|
if (Recursive) list += "'" + InstrumentsDb::toEscapedPath(dirs->at(i)) + "'"; |
|
|
else list += "'" + InstrumentsDb::toEscapedName(dirs->at(i)) + "'"; |
|
2358 |
} |
} |
2359 |
|
|
2360 |
result.Add(list); |
result.Add(list); |
2531 |
|
|
2532 |
for (int i = 0; i < instrs->size(); i++) { |
for (int i = 0; i < instrs->size(); i++) { |
2533 |
if (list != "") list += ","; |
if (list != "") list += ","; |
2534 |
|
list += "'" + InstrumentsDb::toEscapedPath(instrs->at(i)) + "'"; |
|
if (Recursive) list += "'" + InstrumentsDb::toEscapedPath(instrs->at(i)) + "'"; |
|
|
else list += "'" + InstrumentsDb::toEscapedName(instrs->at(i)) + "'"; |
|
2535 |
} |
} |
2536 |
|
|
2537 |
result.Add(list); |
result.Add(list); |