public override List <IWorkspaceContribution> GetContributions()
        {
            List <IWorkspaceContribution> contrib = new List <IWorkspaceContribution>();

            contrib.Add(new MenuWorkspaceContribution(this, "ShowGazetteer", (obj, e) => { ShowEGaz(); },
                                                      String.Format("{{'Name':'View', 'Header':'{0}','InsertAfter':'File'}}", _R("Gazetteer.Menu.View")),
                                                      String.Format("{{'Name':'ShowGazetteer', 'Header':'{0}'}}", _R("Gazetteer.Menu.ShowExplorer"))
                                                      ));

            contrib.Add(new MenuWorkspaceContribution(this, "ShowEGazConverter", (obj, e) => { ShowEGazConverter(); },
                                                      String.Format("{{'Name':'Tools', 'Header':'_Tools','InsertAfter':'File'}}"),
                                                      String.Format("{{'Name':'eGaz', 'Header':'eGaz'}}"), String.Format("{{'Name':'ShowEGazConverter', 'Header':'Legacy eGaz file converter'}}")
                                                      ));

            contrib.Add(new MenuWorkspaceContribution(this, "ShowFindNearestPlace", (obj, e) => { ShowNearestNamedPlace(); },
                                                      String.Format("{{'Name':'Tools', 'Header':'_Tools','InsertAfter':'File'}}"),
                                                      String.Format("{{'Name':'eGaz', 'Header':'eGaz'}}"), String.Format("{{'Name':'ShowFindNearestPlace', 'Header':'_Find nearest named place'}}")
                                                      ));

            contrib.Add(new MenuWorkspaceContribution(this, "ShowCoordCalculator", (obj, e) => { ShowCoordCalculator(); },
                                                      String.Format("{{'Name':'Tools', 'Header':'_Tools','InsertAfter':'File'}}"),
                                                      String.Format("{{'Name':'eGaz', 'Header':'eGaz'}}"), String.Format("{{'Name':'ShowCoordCalculator', 'Header':'_Coordinate calculator'}}")
                                                      ));

            _gazetteer = new Gazetteer(this);
            if (!Preferences.UseFloatingEGaz.Value)
            {
                _gazetteerContrib = new ExplorerWorkspaceContribution <Gazetteer>(this, "Gazetteer", _gazetteer, _R("Gazetteer.Title"), (explorer) => { });
                contrib.Add(_gazetteerContrib);
            }

            return(contrib);
        }
        public override void Select <T>(LookupOptions options, Action <SelectionResult> success, SelectOptions selectOptions)
        {
            Gazetteer g = ShowEGaz();

            if (g != null)
            {
                var placeNameOptions = selectOptions as NamedPlaceSelectionOptions;
                if (placeNameOptions != null && !String.IsNullOrEmpty(placeNameOptions.PlaceNameSeed))
                {
                    g.txtFind.Text = placeNameOptions.PlaceNameSeed;
                }
                g.BindSelectCallback(success);
            }
        }