Пример #1
0
        public MultiStringSlice(int hvoObj, int flid, int ws, bool forceIncludeEnglish, bool editable, bool spellCheck)
            : base(new LabeledMultiStringView(hvoObj, flid, ws, forceIncludeEnglish, editable, spellCheck), hvoObj, flid)
        {
            LabeledMultiStringView view = Control as LabeledMultiStringView;

            view.Display += new VwEnvEventHandler(view_Display);
            view.RightMouseClickedEvent += new FwRightMouseClickEventHandler(HandleRightMouseClickedEvent);
            view.LostFocus += new EventHandler(view_LostFocus);
        }
Пример #2
0
        public MultiStringSlice(ICmObject obj, int flid, int ws, int wsOptional, bool forceIncludeEnglish, bool editable, bool spellCheck)
        {
            var view = new LabeledMultiStringView(obj.Hvo, flid, ws, wsOptional, forceIncludeEnglish, editable, spellCheck);

            Control = view;
#if _DEBUG
            Control.CheckForIllegalCrossThreadCalls = true;
#endif
            InternalInitialize();
            Reuse(obj, flid);
            view.InnerView.Display += view_Display;
            view.InnerView.RightMouseClickedEvent += HandleRightMouseClickedEvent;
            view.InnerView.LostFocus += view_LostFocus;
        }
Пример #3
0
        private ILgWritingSystem[] GetVisibleWritingSystems(string singlePropertySequenceValue)
        {
            string[]     icuLocales   = ChoiceGroup.DecodeSinglePropertySequenceValue(singlePropertySequenceValue);
            Set <string> icuLocaleSet = new Set <string>(icuLocales);
            List <int>   wsList       = new List <int>();

            // convert the icu locale ids into hvo ids.
            foreach (ILgWritingSystem lws in WritingSystemOptionsForDisplay)
            {
                if (icuLocaleSet.Contains(lws.ICULocale))
                {
                    wsList.Add(lws.Hvo);
                }
            }
            // convert the ws hvos into ws object array.
            return(LabeledMultiStringView.WssFromHvos(wsList.ToArray(), Cache));
        }
Пример #4
0
 private static string EncodeWssToDisplayPropertyValue(List <int> hvos, FdoCache cache)
 {
     return(EncodeWssToDisplayPropertyValue(LabeledMultiStringView.WssFromHvos(hvos.ToArray(), cache)));
 }