mirror of
https://github.com/levinsv/pgadmin3.git
synced 2026-05-15 14:15:49 -06:00
Double the single quote.
Добавлена команда удвоения одиночной кавычки в выделеном тексте и обратная команда.
This commit is contained in:
parent
2bb2ff25cf
commit
614a7f0adc
6 changed files with 40 additions and 0 deletions
|
|
@ -787,7 +787,27 @@ void ctlSQLBox::OnKeyDown(wxKeyEvent &event)
|
|||
else
|
||||
event.Skip();
|
||||
}
|
||||
bool ctlSQLBox::BlockDouble(bool undouble)
|
||||
{
|
||||
int start = GetSelectionStart();
|
||||
|
||||
if (!GetSelectedText().IsEmpty())
|
||||
{
|
||||
wxString selection = GetSelectedText();
|
||||
if (!undouble)
|
||||
{
|
||||
selection.Replace("'", "''");
|
||||
}
|
||||
else
|
||||
{
|
||||
selection.Replace("''", "'");
|
||||
|
||||
}
|
||||
ReplaceSelection(selection);
|
||||
SetSelection(start, start + selection.Length());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
bool ctlSQLBox::BlockComment(bool uncomment)
|
||||
{
|
||||
wxString lineEnd;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue