Skip to content

Commit 2a1738b

Browse files
committed
Merged revision(s) 4491-4510, 3462-4491 from tags/version-4.8.6:
This updates the trunk with changes made in release 4.8.6.
1 parent 1b97e3f commit 2a1738b

File tree

11 files changed

+863
-245
lines changed

11 files changed

+863
-245
lines changed

Docs/ChangeLogs/ChangeLog-v4.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@
1111
; Change Log for CodeSnip Release 4
1212
; ------------------------------------------------------------------------------
1313

14+
Release v4.8.6 of 28 February 2014
15+
+ Improved operating system detection to handle Windows 8.1.
16+
+ Added compatibility section to application manifest that declares the program has been tested with Windows Vista and Windows 7.
17+
1418
Release v4.8.5 of 13 January 2014
1519
+ Fixed bug #91 "Generated units won't compile on Delphi XE5" (http://bit.ly/1eBjym2). Compiler directives that are used to change compiler warnings now includes a conditionally compiled $LEGACYIFEND ON directive.
1620
+ Fixed potential bug when checking for the existence of files. It had been possible that a "sym-link" to a file could give misleading results.

Src/3rdParty/PJSysInfo.pas

Lines changed: 774 additions & 135 deletions
Large diffs are not rendered by default.

Src/Compilers.UBorland.pas

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* v. 2.0. If a copy of the MPL was not distributed with this file, You can
44
* obtain one at http://mozilla.org/MPL/2.0/
55
*
6-
* Copyright (C) 2006-2013, Peter Johnson (www.delphidabbler.com).
6+
* Copyright (C) 2006-2014, Peter Johnson (www.delphidabbler.com).
77
*
88
* $Rev$
99
* $Date$
@@ -180,7 +180,7 @@ function TBorlandCompiler.InstallPathFromReg(const RootKey: HKEY): string;
180180
var
181181
Reg: TRegistry; // registry accessor
182182
begin
183-
if TOSInfo.CheckReportedOS(TOSInfo.WinXP) then
183+
if TOSInfo.IsReallyWindowsXPOrGreater then
184184
Reg := TRegistry.Create(KEY_READ or KEY_WOW64_64KEY)
185185
else
186186
// KEY_WOW64_64KEY is not supported on Windows 2000

Src/FmProxyServerDlg.pas

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* v. 2.0. If a copy of the MPL was not distributed with this file, You can
44
* obtain one at http://mozilla.org/MPL/2.0/
55
*
6-
* Copyright (C) 2009-2013, Peter Johnson (www.delphidabbler.com).
6+
* Copyright (C) 2009-2014, Peter Johnson (www.delphidabbler.com).
77
*
88
* $Rev$
99
* $Date$
@@ -143,7 +143,7 @@ procedure TProxyServerDlg.ConfigForm;
143143
TFontHelper.SetDefaultBaseFont(lblIPAddressReq.Font);
144144
TFontHelper.SetDefaultBaseFont(lblPortReq.Font);
145145
TFontHelper.SetDefaultBaseFont(lblReqSymbol.Font);
146-
if TOSInfo.IsVistaOrLater then
146+
if TOSInfo.IsReallyWindowsVistaOrGreater then
147147
begin
148148
edPassword1.PasswordChar := '';
149149
edPassword2.PasswordChar := '';

Src/Res/Misc/CodeSnip.manifest

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,15 @@
55
* v. 2.0. If a copy of the MPL was not distributed with this file, You can
66
* obtain one at http://mozilla.org/MPL/2.0/
77
*
8-
* Copyright (C) 2012, Peter Johnson (www.delphidabbler.com).
8+
* Copyright (C) 2012-2014, Peter Johnson (www.delphidabbler.com).
99
*
1010
* $Rev$
1111
* $Date$
1212
*
13-
* Manifest file specifying UI for use in XP and execution level required for
14-
* Vista.
13+
* CodeSnip's Windows manifest file.
14+
*
15+
* GUIDs used in compatibility section taken from
16+
* http://msdn.microsoft.com/en-us/library/windows/desktop/dn481241.aspx
1517
-->
1618

1719
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
@@ -39,4 +41,12 @@
3941
</requestedPrivileges>
4042
</security>
4143
</trustInfo>
44+
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
45+
<application>
46+
<!-- App has been tested on Windows 7 -->
47+
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>
48+
<!-- App has been tested on Windows Vista -->
49+
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>
50+
</application>
51+
</compatibility>
4252
</assembly>

Src/UBaseObjects.pas

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* v. 2.0. If a copy of the MPL was not distributed with this file, You can
44
* obtain one at http://mozilla.org/MPL/2.0/
55
*
6-
* Copyright (C) 2005-2013, Peter Johnson (www.delphidabbler.com).
6+
* Copyright (C) 2005-2014, Peter Johnson (www.delphidabbler.com).
77
*
88
* $Rev$
99
* $Date$
@@ -53,14 +53,15 @@ interface
5353

5454
{
5555
TNoConstructObject:
56-
Class that fails if its constructor is called. Provided as a base class for
57-
classes that contain only class methods and should never be constructed.
56+
Class that raises an exception if its constructor is called. Provided as a
57+
base class for classes that contain only class methods and should never be
58+
constructed.
5859
}
5960
TNoConstructObject = class(TObject)
6061
public
6162
constructor Create;
62-
{Class constructor. Causes an assertion failure if called. The object is
63-
never constructed.
63+
{Prevents construction of an object instance by raising an
64+
ENoConstructException if called.
6465
}
6566
end;
6667

@@ -79,8 +80,8 @@ TNoPublicConstructObject = class(TObject)
7980
}
8081
public
8182
constructor Create;
82-
{Class constructor. Causes an assertion failure if called. The object is
83-
never constructed.
83+
{Prevents construction of an object instance by raising an
84+
ENoConstructException if called.
8485
}
8586
end;
8687

@@ -100,8 +101,8 @@ TNoPublicConstructIntfObject = class(TInterfacedObject)
100101
}
101102
public
102103
constructor Create;
103-
{Class constructor. Causes an assertion failure if called. The object is
104-
never constructed.
104+
{Prevents construction of an object instance by raising an
105+
ENoConstructException if called.
105106
}
106107
end;
107108

@@ -249,8 +250,8 @@ implementation
249250
{ TNoConstructObject }
250251

251252
constructor TNoConstructObject.Create;
252-
{Class constructor. Causes an assertion failure if called. The object is never
253-
constructed.
253+
{Prevents construction of an object instance by raising an
254+
ENoConstructException if called.
254255
}
255256
begin
256257
raise ENoConstructException.Create(
@@ -261,8 +262,8 @@ constructor TNoConstructObject.Create;
261262
{ TNoPublicConstructObject }
262263

263264
constructor TNoPublicConstructObject.Create;
264-
{Class constructor. Causes an assertion failure if called. The object is
265-
never constructed.
265+
{Prevents construction of an object instance by raising an
266+
ENoConstructException if called.
266267
}
267268
begin
268269
raise ENoConstructException.Create(
@@ -282,8 +283,8 @@ constructor TNoPublicConstructObject.InternalCreate;
282283
{ TNoPublicConstructIntfObject }
283284

284285
constructor TNoPublicConstructIntfObject.Create;
285-
{Class constructor. Causes an assertion failure if called. The object is never
286-
constructed.
286+
{Prevents construction of an object instance by raising an
287+
ENoConstructException if called.
287288
}
288289
begin
289290
raise ENoConstructException.Create(

Src/UFontHelper.pas

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* v. 2.0. If a copy of the MPL was not distributed with this file, You can
44
* obtain one at http://mozilla.org/MPL/2.0/
55
*
6-
* Copyright (C) 2006-2013, Peter Johnson (www.delphidabbler.com).
6+
* Copyright (C) 2006-2014, Peter Johnson (www.delphidabbler.com).
77
*
88
* $Rev$
99
* $Date$
@@ -197,7 +197,7 @@ class procedure TFontHelper.SetContentFont(const Font: TFont);
197197
Font.Name := DefaultContentFontName;
198198
Font.Size := DefaultContentFontSize;
199199
Font.Style := [];
200-
if TOSInfo.CheckReportedOS(TOSInfo.WinVista) then
200+
if TOSInfo.IsReallyWindowsVistaOrGreater then
201201
begin
202202
// We have Vista or later - use Calibri if installed
203203
if FontExists(VistaContentFontName) then
@@ -259,7 +259,7 @@ class procedure TFontHelper.SetDefaultFont(const Font: TFont);
259259
Font.Name := DefaultFontName;
260260
Font.Size := DefaultFontSize;
261261
Font.Style := [];
262-
if TOSInfo.CheckReportedOS(TOSInfo.WinVista) then
262+
if TOSInfo.IsReallyWindowsVistaOrGreater then
263263
begin
264264
// Vista or later
265265
if FontExists(VistaFontName) then

Src/UMarquee.pas

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* v. 2.0. If a copy of the MPL was not distributed with this file, You can
44
* obtain one at http://mozilla.org/MPL/2.0/
55
*
6-
* Copyright (C) 2008-2013, Peter Johnson (www.delphidabbler.com).
6+
* Copyright (C) 2008-2014, Peter Johnson (www.delphidabbler.com).
77
*
88
* $Rev$
99
* $Date$
@@ -50,6 +50,8 @@ TMarquee = class abstract(TProgressBar)
5050
/// </summary>
5151
/// <param name="AOwner">TComponent [in] Reference to owning component.
5252
/// </param>
53+
/// <exception>ENoConstructException raised if constructor called directly
54+
/// on TMarquee instead of via sub-classes.</exception>
5355
/// <remarks>This constructor must not be called directly, only by
5456
/// sub-classes. Users of TMarquee must call CreateInstance instead.
5557
/// </remarks>
@@ -153,7 +155,8 @@ class function TMarquee.CreateInstance(AOwner: TComponent): TMarquee;
153155
class function TMarquee.IsBuiltInMarqueeAvailable: Boolean;
154156
begin
155157
// We only use built in marquee on Vista or later when themes are enabled
156-
Result := TOSInfo.IsVistaOrLater and ThemeServicesEx.ThemesEnabled;
158+
Result := TOSInfo.IsReallyWindowsVistaOrGreater
159+
and ThemeServicesEx.ThemesEnabled;
157160
end;
158161

159162
{ TEmulatedMarquee }

0 commit comments

Comments
 (0)