private void BindLanguageOptions()
        {
            Dictionary <string, Node> cultureNodes = this._module.GetCultureRootNodesBySite(base.PageEngine.CurrentSite);
            HtmlGenericControl        listControl  = new HtmlGenericControl("ul");

            listControl.EnableViewState = false;

            foreach (KeyValuePair <string, Node> cultureNode in cultureNodes)
            {
                string languageAsText = Globalization.GetNativeLanguageTextFromCulture(cultureNode.Key);
                switch (this._module.DisplayMode)
                {
                case DisplayMode.Text:
                    AddLanguageLink(cultureNode.Key, cultureNode.Value, listControl, languageAsText, false);
                    break;

                case DisplayMode.Flag:
                    AddLanguageLink(cultureNode.Key, cultureNode.Value, listControl, languageAsText, true);
                    break;

                case DisplayMode.DropDown:
                    AddDropDownOption(cultureNode.Key, languageAsText);
                    break;
                }

                // Also add the language and root url to the list of possible redirectable urls. We can use this
                // later to redirect to the root node that corresponds with the browser language if there is no
                // specific page requested.
                if (cultureNode.Key != base.PageEngine.RootNode.Culture)
                {
                    this._homePagesForLanguages.Add(Globalization.GetLanguageFromCulture(cultureNode.Key), UrlHelper.GetUrlFromNode(cultureNode.Value));
                }
            }
            if (this._module.DisplayMode == DisplayMode.Text || this._module.DisplayMode == DisplayMode.Flag)
            {
                this.plhLanguageLinks.Controls.Add(listControl);
            }
        }