Skip to content

Commit

Permalink
Merge branch 'release-7.2.4'
Browse files Browse the repository at this point in the history
  • Loading branch information
bovender committed Nov 18, 2016
2 parents a6170c9 + c480b01 commit 0117d53
Show file tree
Hide file tree
Showing 9 changed files with 52 additions and 29 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ repository:
- Change the startup project of the XLToolbox solution to
`XLToolboxForExcel` by right-clicking on this project.

When building the DLLs, make sure to use the `Release` configuration to
avoid additional dependencies that may not be met on all target systems
when the `Debug` configuration is used (namely, `MSCVR120D.DLL`).


Notes regarding Debug configuration
--------------------------------
Expand Down
4 changes: 2 additions & 2 deletions Tests/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("7.2.3.0")]
[assembly: AssemblyFileVersion("7.2.3.0")]
[assembly: AssemblyVersion("7.2.4.0")]
[assembly: AssemblyFileVersion("7.2.4.0")]
4 changes: 2 additions & 2 deletions VERSION
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
7.2.3
7.2.3.0
7.2.4
7.2.4.0
28 changes: 23 additions & 5 deletions XLToolbox/Export/BatchExporter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ public BatchExporter(BatchExportSettings settings)
: base()
{
Settings = settings;
_exporter = new Exporter(settings.Preset);
}

#endregion
Expand Down Expand Up @@ -180,8 +179,8 @@ private void ExportSheetLayout(dynamic sheet)
Logger.Fatal("ExportSheetLayout: Object type '{0}' not implemented!", Settings.Objects);
throw new NotImplementedException(Settings.Objects.ToString());
}
_exporter.FileName = _batchFileName.GenerateNext(sheet, Instance.Default.Application.Selection);
_exporter.Execute();
Exporter.FileName = _batchFileName.GenerateNext(sheet, Instance.Default.Application.Selection);
Exporter.Execute();
}

private void ExportSheetItems(dynamic sheet)
Expand Down Expand Up @@ -251,8 +250,8 @@ private void ExportSelection(dynamic sheet)
Logger.Info("ExportSelection");
Logger.Info("ExportSelection: Sheet: {0}", sheet.Name);
dynamic selection = Instance.Default.Application.Selection;
_exporter.FileName = _batchFileName.GenerateNext(sheet, selection);
_exporter.Execute();
Exporter.FileName = _batchFileName.GenerateNext(sheet, selection);
Exporter.Execute();
}

#endregion
Expand Down Expand Up @@ -350,6 +349,25 @@ private int CountInSheetItems(dynamic worksheet)

#endregion

#region Private properties

/// <summary>
/// Creates a new exporter object using the current settings' preset.
/// </summary>
private Exporter Exporter
{
get
{
if (_exporter == null)
{
_exporter = new Exporter(Settings.Preset);
}
return _exporter;
}
}

#endregion

#region Private fields

private Exporter _exporter;
Expand Down
2 changes: 1 addition & 1 deletion XLToolbox/Export/ViewModels/ColorProfileViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ public void TransformFromStandardProfile(FreeImageAPI.FreeImageBitmap freeImageB

// Create transform with perceptual intent (0) and no special options (0)
cmsHTransform t = cmsCreateTransform(
standardProfile, GetLcmsPixelFormat(freeImageBitmap),
standardProfile, Lcms.Formatters.TYPE_BGRA_8,
targetProfile, GetLcmsPixelFormat(ColorSpace),
0, 0);
if (t == cmsHTransform.Zero)
Expand Down
27 changes: 14 additions & 13 deletions XLToolbox/Export/ViewModels/PresetViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -164,11 +164,6 @@ public ColorSpaceProvider ColorSpace
{
_preset.UseColorProfile = true;
this.Transparency.AsEnum = Models.Transparency.WhiteCanvas;
_mustUseColorProfile = true;
}
else
{
_mustUseColorProfile = false;
}
SanitizeSettings();
Expand Down Expand Up @@ -243,18 +238,24 @@ public bool UseColorProfile
}
}


/// <summary>
/// Gets whether the "Use color profile" option is enabled.
/// </summary>
/// <remarks>
/// To be able to use color profiles, there must be at least one color
/// profile file, and the chosen file type must be a bitmap format.
/// On the other hand, if the color type is CMYK, using a color
/// profile is mandatory and the option is disabled (cannot be toggled
/// by the user).
/// </remarks>
public bool IsUseColorProfileEnabled
{
get
{
return (ColorProfiles.Profiles.Count > 0)
&& !_preset.IsVectorType
&& !_mustUseColorProfile;
}
protected set
{
_mustUseColorProfile = value;
OnPropertyChanged("IsUseColorProfileEnabled");
return (ColorProfiles.Profiles.Count > 0) // must have color profiles
&& !_preset.IsVectorType // must not be a vector type
&& !(ColorSpace.AsEnum == Models.ColorSpace.Cmyk);
}
}

Expand Down
4 changes: 2 additions & 2 deletions XLToolbox/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("7.2.3.0")]
[assembly: AssemblyFileVersion("7.2.3.0")]
[assembly: AssemblyVersion("7.2.4.0")]
[assembly: AssemblyFileVersion("7.2.4.0")]
4 changes: 2 additions & 2 deletions XLToolboxForExcel/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("7.2.3.0")]
[assembly: AssemblyFileVersion("7.2.3.0")]
[assembly: AssemblyVersion("7.2.4.0")]
[assembly: AssemblyFileVersion("7.2.4.0")]

[assembly: NeutralResourcesLanguageAttribute("en-US")]
4 changes: 2 additions & 2 deletions XLToolboxForExcel/ThisAddIn.cs
Original file line number Diff line number Diff line change
Expand Up @@ -199,11 +199,11 @@ private void PerformSanityChecks()
XLToolbox.Logging.LogFileViewModel vm = new XLToolbox.Logging.LogFileViewModel();
if (userSettings.EnableLogging)
{
vm.InjectInto<XLToolbox.Logging.IncompleteShutdownLoggingEnabled>().ShowDialogInForm();
vm.InjectInto<XLToolbox.Logging.IncompleteShutdownLoggingEnabled>().ShowInForm();
}
else
{
vm.InjectInto<XLToolbox.Logging.IncompleteShutdownLoggingDisabled>().ShowDialogInForm();
vm.InjectInto<XLToolbox.Logging.IncompleteShutdownLoggingDisabled>().ShowInForm();
}
userSettings.SheetManagerVisible = false;
}
Expand Down

0 comments on commit 0117d53

Please sign in to comment.