truncated_end = ConvertRectToPixel(device_scale_factor, truncated_end);
UpdateSelectionDataAndShow(
- truncated_start, truncated_end, false /*not used*/, false /*show*/);
+ truncated_start, truncated_end, false /*show*/);
}
void SelectionControllerEfl::UpdateSelectionData(const base::string16& text) {
bool SelectionControllerEfl::UpdateSelectionDataAndShow(
const gfx::Rect& left_rect,
const gfx::Rect& right_rect,
- bool,
bool show) {
TRACE_EVENT0("selection,efl", __PRETTY_FUNCTION__);
if (!show && !IsSelectionValid(left_rect, right_rect)) {
}
gfx::Rect left = selection_data_->GetLeftRect();
- if(selection_data_->GetCaretSelectionStatus()) {
+ if (selection_data_->GetCaretSelectionStatus()) {
input_handle_->SetBasePosition(gfx::Point(left.x(), left.y()));
input_handle_->Move(left.bottom_right());
input_handle_->Show();
ShowContextMenu();
return;
- } else {
- input_handle_->Hide();
}
+ input_handle_->Hide();
if (left.x() == 0 && left.y() == 0 && right.x() == 0 && right.y() == 0) {
selection_data_->ClearRectData();
UpdateSelectionDataAndShow(
GetLeftRect(),
GetRightRect(),
- false /* unused */,
should_restore_selection_menu_);
}
}
if (GetSelectionEditable()){
SetCaretSelectionStatus(true);
UpdateSelectionDataAndShow(
- GetLeftRect(), GetRightRect(), false /* unused */, false);
+ GetLeftRect(), GetRightRect(), false);
} else {
SetSelectionEditable(true);
}
// To update the selection bounds
// returns false if rects are invalid, otherwise true
bool UpdateSelectionDataAndShow(const gfx::Rect& left_rect,
- const gfx::Rect& right_rect, bool is_anchor_first, bool show = true);
+ const gfx::Rect& right_rect, bool show = true);
void GetSelectionBounds(gfx::Rect* left, gfx::Rect* right);
// Handles the mouse press,move and relase events on selection handles
void OnMouseDown(const gfx::Point& touch_point, SelectionHandleEfl*);