Skip to content

Commit 3244942

Browse files
Fix LT-22145: Make non-multilingual string slice default to 1st analysis
1 parent 850ff32 commit 3244942

2 files changed

Lines changed: 13 additions & 1 deletion

File tree

Src/Common/Controls/DetailControls/StringSlice.cs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -378,6 +378,10 @@ public override void Display(IVwEnv vwenv, int hvo, int frag)
378378
#endregion // View Constructors
379379

380380
#region RootSite implementation
381+
/// <summary>
382+
/// This is a RootSiteControl that displays a non-multilingual string slice
383+
/// Data entry should always default to the DefaultAnalWs writing system according to LT-22145
384+
/// </summary>
381385
class StringSliceView : RootSiteControl, INotifyControlInCurrentSlice
382386
{
383387
ICmObject m_obj;
@@ -421,6 +425,14 @@ public int DefaultWs
421425
(m_vc as StringSliceVc).DefaultWs = value;
422426
}
423427
}
428+
429+
public override int WsPending
430+
{
431+
// Ignore requests to set pending writing system, this slice always deals with the DefaultAnalWs.
432+
// ReSharper disable once ValueParameterNotUsed
433+
set { }
434+
get => Cache != null ? Cache.DefaultAnalWs : -1;
435+
}
424436
#region IDisposable override
425437

426438
/// <summary>

Src/Common/SimpleRootSite/SimpleRootSite.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1692,7 +1692,7 @@ public virtual Rectangle AdjustedClientRectangle
16921692
/// informtion away and reset the keyboard).
16931693
/// </remarks>
16941694
/// -----------------------------------------------------------------------------------
1695-
public int WsPending
1695+
public virtual int WsPending
16961696
{
16971697
get
16981698
{

0 commit comments

Comments
 (0)