mirror of
https://github.com/levinsv/pgadmin3.git
synced 2026-05-25 22:03:16 -06:00
Add "Copy list columns header" context command SQL Result
Добавлено копирование в буфер обмена списка имен и типов колонок результата запроса.
This commit is contained in:
parent
8c123b0550
commit
0ec8c60a68
6 changed files with 51 additions and 3 deletions
|
|
@ -332,6 +332,36 @@ wxString ctlSQLResult::OnGetItemText(long item, long col) const
|
|||
}
|
||||
return wxEmptyString;
|
||||
}
|
||||
wxString ctlSQLResult::CopySelColumnNameType()
|
||||
{
|
||||
size_t i;
|
||||
wxString ss = wxEmptyString;
|
||||
if (GetSelectedCols().GetCount()) {
|
||||
wxArrayInt cols = GetSelectedCols();
|
||||
int err = 0;
|
||||
int noformat = 0;
|
||||
int dtType = -1;
|
||||
//AppendColumnHeader(str, cols);
|
||||
//str.Append(GetExportLine(i, cols));
|
||||
for (size_t col = 0; col < cols.Count(); col++)
|
||||
{
|
||||
int cl = cols[col];
|
||||
bool isDt = false;
|
||||
wxString colName = colNames.Item(cl);
|
||||
wxString colType = colTypes.Item(cl);
|
||||
if (!ss.IsEmpty()) ss.Append(", ");
|
||||
ss.Append(colName + " " + colType);
|
||||
|
||||
}
|
||||
}
|
||||
if (wxTheClipboard->Open())
|
||||
{
|
||||
wxTheClipboard->SetData(new wxTextDataObject(ss));
|
||||
wxTheClipboard->Close();
|
||||
}
|
||||
|
||||
return ss;
|
||||
}
|
||||
wxString ctlSQLResult::CheckSelColumnDate()
|
||||
{
|
||||
size_t i;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue