REPLACE : addition done
This commit is contained in:
@@ -1202,9 +1202,9 @@ void BufferText::Replace(Edn::String &data)
|
||||
bool haveSelectionActive = m_EdnBuf.GetSelectionPos(SELECTION_PRIMARY, SelectionStart, SelectionEnd, SelectionIsRect, SelectionRectStart, SelectionRectEnd);
|
||||
if (true == haveSelectionActive) {
|
||||
// Replace Data :
|
||||
// TODO : Reset this : ... m_EdnBuf.ReplaceSelected(SELECTION_PRIMARY, data.GetDirectPointer());//, strlen(data.GetDirectPointer()));
|
||||
// TODO : Reset this : ... SetInsertPosition(SelectionStart + strlen(data.GetDirectPointer()));
|
||||
|
||||
Edn::VectorType<int8_t> myData = data.GetVector();
|
||||
m_EdnBuf.ReplaceSelected(SELECTION_PRIMARY, myData);
|
||||
SetInsertPosition(SelectionStart + myData.Size());
|
||||
}
|
||||
SetModify(true);
|
||||
}
|
||||
|
@@ -192,15 +192,15 @@ void Search::Display(GtkWindow *parent)
|
||||
} else {
|
||||
gtk_widget_set_sensitive(m_CkMatchCase, true);
|
||||
}
|
||||
|
||||
Edn::String myDataString;
|
||||
SearchData::GetSearch(myDataString);
|
||||
// Remove data form the search
|
||||
Edn::String myDataString = "";
|
||||
SearchData::SetSearch(myDataString);
|
||||
gtk_entry_set_text(GTK_ENTRY(m_searchEntry), myDataString.c_str());
|
||||
if (0 == strlen(myDataString.c_str())) {
|
||||
//if (0 == strlen(myDataString.c_str())) {
|
||||
m_haveSearchData = false;
|
||||
} else {
|
||||
m_haveSearchData = true;
|
||||
}
|
||||
//} else {
|
||||
// m_haveSearchData = true;
|
||||
//}
|
||||
|
||||
SearchData::GetReplace(myDataString);
|
||||
gtk_entry_set_text(GTK_ENTRY(m_replaceEntry), myDataString.c_str());
|
||||
@@ -220,6 +220,10 @@ void Search::Display(GtkWindow *parent)
|
||||
gtk_widget_set_sensitive(m_BtReplaceAndNext, m_haveReplaceData);
|
||||
}
|
||||
|
||||
// set focus on a specific widget :
|
||||
gtk_window_set_focus(parent, m_searchEntry);
|
||||
|
||||
|
||||
// display the dialogue box
|
||||
gtk_widget_show_all(m_localDialog);
|
||||
|
||||
|
@@ -584,6 +584,8 @@ Edn::VectorType<int8_t> Edn::String::GetVector(void)
|
||||
return out;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @brief Unitary test for the string system
|
||||
*
|
||||
|
Reference in New Issue
Block a user