File diff r15552:db706a5de04a → r15553:7db2c5732f29
src/bridge_gui.cpp
Show inline comments
 
@@ -246,19 +246,16 @@ public:
 

	
 
	virtual void OnClick(Point pt, int widget, int click_count)
 
	{
 
		switch (widget) {
 
			default: break;
 
			case BBSW_BRIDGE_LIST: {
 
				uint i = ((int)pt.y - this->GetWidget<NWidgetBase>(BBSW_BRIDGE_LIST)->pos_y) / this->resize.step_height;
 
				if (i < this->vscroll.GetCapacity()) {
 
					i += this->vscroll.GetPosition();
 
					if (i < this->bridges->Length()) {
 
						this->BuildBridge(i);
 
						delete this;
 
					}
 
				uint i = this->vscroll.GetScrolledRowFromWidget(pt.y, this, BBSW_BRIDGE_LIST);
 
				if (i < this->bridges->Length()) {
 
					this->BuildBridge(i);
 
					delete this;
 
				}
 
			} break;
 

	
 
			case BBSW_DROPDOWN_ORDER:
 
				this->bridges->ToggleSortOrder();
 
				this->SetDirty();