Rockford Lhotka
    CTO at Magenic
    Author, speaker, software architect
    Creator of the CSLA .NET framework

Home
Blog
CSLA .NET
Magenic
Speaking
Publications
About me
Contact me

Login

Version 3.8.0 change log

 

This document is the change log for version 3.8.0 of CSLA .NET for Silverlight.

 

For a more complete list of changes, go to http://www.lhotka.net/cslabugs, select “all issues” and filter the status to “closed” and/or “checked in”.

 

Click here for a list of known issues with this version.

 

Release 3.8.0-091105:

 

ViewModelBase (091105)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=634

The OnModelChanged() parameters are now strongly typed.

 

Test project warnings (091104)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=631

Eliminated warnings in the unit/integration test projects.

 

XML comments (091104)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=272

All CSLA .NET framework code should now be commented.

 

Validation (091103)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=630

ValidationComplete event is now raised immediately upon completion of all sync rules if there are no async rules. Otherwise it is still raised when all async rules complete as was the case prior to this change.

 

Pre-Release 3.8.0-091030:

 

Samples (091030)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=587

Updated most remaining sample apps for 3.8 and SL3.

 

InvokeMethod (091030)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=628

Hooking PropertyChanged on the target object (DataContext or whatever) AND hooking the trigger event off the UI control turns out to be essentially impossible. The implementation we've had couldn't handle the case where the DataContext changed during the lifetime of the form, and trying to address that issue would have caused a memory leak.

 

In the end, it is almost certainly better if the UI control bind its IsEnabled (or whatever) property explicitly to control the visuals anyway, as that's more explicit and flexible.

 

Unfortunately this is a breaking change, because ManualEnableControl is now gone, and InvokeMethod now always operates as though that property were set to false.

 

ViewModelBase (091026)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=619

Add protected method OnModelChanged() so a subclass can hook events from the model as needed.

 

ViewModelBase (091026)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=617

Fix issue where the Model property being changed didn’t trigger proper notification to the UI.

 

InvokeMethod (091026)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=618

Fix issue where the Target property wasn’t always properly overriding the DataContext value.

 

Pre-Release 3.8.0-091025:

 

BusyAnimation (091025)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=596

Fixed issue with memory leak when using BusyAnimation (and therefore PropertyStatus).

 

Samples (091022)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=587

Updated for 3.8: InventoryDemo, SimpleApp, SilverlightSOA, Rolodex, RolodexUsingPrism, SimpleAppvb, MVVMExperimentSL, NavigationApp, RemotePortalWithCompressedProxy

 

InvokeMethod and Execute (091022)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=605

InvokeMethod and Execute now support exactly two method signatures for target methods. A target method may have 0 or 2 parameters. If the method has 2 parameters, the method must follow this signature:

 

public void Method(object sender, ExecuteEventArgs e)

 

This is a breaking change for InvokeMethod from previous 3.8 releases, because the 1 and 3 parameter options have been eliminated. This is an enhancement for Execute because the 0 parameter option has been added.

 

ViewModelBase (091022)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=606

Added OnError() method and ErrorOccurred event to ViewModelBase. OnError() is invoked when a non-null value is set in the Error property, and OnError() raises the ErrorOccurred event. This simplifies code in the UI or viewmodel subclass when an error needs to be handled.

 

InvokeMethod (091020)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=593

When InvokeMethod calls a two parameter target method, the parameters are now (object, ExecuteEventArgs) to match how Execute works with target methods.

 

ViewModel (091020)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=593

Remove overloads of public methods, leaving only the sender/args versions that work with both Execute and InvokeMethod.

 

ViewModelBase (091020)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=593

Add sync versions of refresh, save and addnew operations for WPF. The async refresh and save behaviors are available in both WPF and Silverlight. The async methods now start with “Begin” instead of “Do”, which is incompatible with Beta 1.

 

Validation/DataAnnotations (091020)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=578

When validation annotation attributes are executed they now have access to the business object itself through the validation context, allowing for cross-property validation rules. Please note that this capability doesn’t exist on the .NET side, so attributes written using this feature won’t work on .NET.

 

Interactivity assembly (091019)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=603

System.Windows.Interactivity assembly is now referenced from a Dependencies folder in the CSLA .NET folder structure. This has the advantage that you don’t need to install the Expression Blend 3 SDK to build CSLA .NET. This has the disadvantage that you lose all localization and integrated help for the assembly. If you need localization or integrated help you’ll need to install the Blend SDK and change the assembly reference to pull the DLL from the SDK install location.

 

svn repository structure (091018)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=592

CSLA .NET 3.8.x is now located in

svn://svn.lhotka.net/csla/core/branches/V3-8-x

 

The /core/trunk folder is now the working folder for version 4.0.0.

 

ViewModel (090917)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=526

Substantial changes to ViewModelBase to bring it in line with the functionality provided by CslaDataProvider. At this point the ViewModelBase and ViewModel properties and methods should offer the same features as the Silverlight CslaDataProvider control.

 

Pre-Release 3.8.0-091003:

 

Validation (090930)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=578

Add support for the data annotation attributes from System.ComponentModel.DataAnnotations. When validation annotation attributes are applied to business object properties, they are now incorporated into the CSLA .NET validation subsystem as business rules, and are executed as priority 0 rules automatically.

 

Pre-Release 3.8.0-090929:

 

EditableRootListBase (090929)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=532

Added a RaiseReplaceEvents property that can override the way Replace events are raised.

 

MobileFormatter (090929)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=549

Add instance level cache of Type objects during deserialization as a performance optimization.

 

ViewModel (090929)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=526

ViewModelBase and ViewModel now exist in CSLA .NET for Windows and are linked into CSLA .NET for Silverlight.

 

Execute (090929)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=521

Execute now exists in CSLA .NET for Windows and is linked into CSLA .NET for Silverlight.

 

InvokeMethod (090929)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=470

InvokeMethod now exists in CSLA .NET for Windows and is linked into CSLA .NET for Silverlight.

 

Field Manager/PropertyInfo<T> (090928)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=563

Add Type parameter to Create() methods so a PropertyInfo factory has access to the business object type that declares the property.

 

Pre-Release 3.8.0-090913:

 

Field Manager/PropertyInfo<T> (090911)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=563

Add Csla.Core.IPropertyInfoFactory, which can be implemented to provide a new factory object to create PropertyInfo<T> instances.

 

Specify that your type should be used as a factory by setting the Csla.Core.FieldManager.PropertyInfoFactory.Factory property to an instance of your factory object.

 

This is necessary to support the scenario where you implement a custom FieldData<T> subclass, and then a custom PropertyInfo<T> subclass, and you want to use the lambda expression overloads of RegisterProperty(). In that case, the RegisterProperty() implementation creates the instance of PropertyInfo<T> on your behalf, and this new factory scheme allows you to have it create your own subclass of PropertyInfo<T>.

 

FieldData (090910)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=562

Mark the MarkClean() method as virtual so a subclass can more easily manage the dirty status.

 

PropertyStatus (090901)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=492

Expose public status properties so a control can bind to PropertyStatus instead of having PropertyStatus manage the control.

 

Properties include CanRead, CanWrite, IsBusy, IsValid, RuleDescription and RuleSeverity. The BrokenRules property was already available, allowing a consumer to access the entire list of broken rules for the property.

 

To use these properties, do not set TargetControl on PropertyStatus. Instead, have the UI control bind its properties to these new properties on PropertyStatus.

 

PropertyStatus (090901)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=492

This is a breaking change.

There's now a Property property, which should be bound to the business object property. It also supports dot notation to drill through a ViewModel or data provider, so the Path part can be like "Data.Name" or "Model.Name".

 

There's now a TargetControl property, which should be element bound to the target UI control that is to be managed by PropertyStatus.

 

<csla:PropertyStatus

       Property="{Binding Path=Price,Mode=TwoWay}"

       TargetControl="{Binding ElementName=PriceTextBox}" /> 

 

 

Pre-Release 3.8.0-090814:

 

CslaDataProvider (090814)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=527

Change control to inherit from FrameworkElement so ObjectInstance property can be a bindable dependency property. This allows CslaDataProvider to be used in a parent-child model, because a child data provider can get its ObjectInstance value from another DataContext value, effectively enabling “chaining” of data providers.

 

Execute trigger action (090814)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=521

Added an Execute trigger action that can be used to invoke methods on the DataContext when an event occurs on the associated control. This uses the new System.Windows.Interactivity functionality that comes with Expression Blend 3.

 

For example:

 

      <TextBox Name="NewIdTextBox" Width="150" Margin="5"/>

      <Button Content="Refresh"

              Tag="{Binding ElementName=NewIdTextBox, Path=Text}">

        <i:Interaction.Triggers>

          <i:EventTrigger EventName="Click">

            <csla:Execute MethodName="Load" />

          </i:EventTrigger>

        </i:Interaction.Triggers>

      </Button>

 

ViewModel (090814)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=526

Added a new ViewModel base class to Csla.Silverlight that can be used to easily create typed ViewModel objects for CSLA .NET Model objects.

 

MobileFormatter (090811)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=500

Enable the use of binary XML serialization. This is now the default option. On the SL side, set the MobileFormatter.UseBinaryXml property to switch back to text XML. On the .NET side use the CslaUseBinaryXml setting in appSettings to use text XML.

 

CslaDataProvider (090803)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=491

Fix issue where the Error property was cleared on a fetch operation when an error actually occurred.

 

PropertyStatus (090731)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=472

This is a breaking change.

Removed the Source property. The control now binds to the DataContext, whether set explicitly on the control, or on a containing control just like any other control.

 

InvokeMethod (090731)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=470

Fixed a bug in MethodParameter that was blocking binding of arbitrary types, now this works:

 

      <ListBox ItemsSource="{Binding Path=Model}"

               ItemTemplate="{StaticResource DataList}"

               csla:InvokeMethod.TriggerEvent="SelectionChanged"

               csla:InvokeMethod.Target="{Binding}"

               csla:InvokeMethod.MethodName="ShowItem"

               csla:InvokeMethod.MethodParameter=

       "{Binding SelectedItem, RelativeSource={RelativeSource Self}}"

               csla:InvokeMethod.ManualEnableControl="True" />

 

InvokeMethod (090731)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=471

This is a breaking change.

Rename Resource property to Target and make it generally bindable so it works against resources, but also element binding or any other valid target.

 

Also fix a bug with ManualEnableControl and do a bunch of general code cleanup.

 

InvokeMethod (090730)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=465

InvokeMethod can now pass the sender and EventArgs references through to the target method. The following method signatures are now valid:

 

void TargetMethod()

void TargetMethod(object paramValue)

void TargetMethod(object sender, object paramValue)

void TargetMethod(object sender, EventArgs e, object paramValue)

 

Combined with a change so the trigger event can now be nearly any event, this change makes it possible to route events from a ListBox or other control to a handler so the handler (such as a ViewModel) can react to the user changing a selection or double-clicking or something.

 

InvokeMethod (090730)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=465

If there is no Can___ property for a method, the default is now to enable the UI control, making it easier to use InvokeMethod with arbitrary target objects.

 

ApplicationContext.LogicalExecutionLocation (090721)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=395

LogicalExecutionLocation has been changed so it now works with nested data portal calls.

 

PropertyStatus (090721)

http://www.lhotka.net/cslabugs/edit_bug.aspx?id=444

Fix an issue where PropertyStatus would disable UI controls rather than just setting IsReadOnly to true.

 

 

 

 

(Updated 11/5/2009 8:37:02 PM)