Presentation is loading. Please wait.

Presentation is loading. Please wait.

Boris Jabes Program Manager Visual C++ Microsoft Corporation.

Similar presentations


Presentation on theme: "Boris Jabes Program Manager Visual C++ Microsoft Corporation."— Presentation transcript:

1 Boris Jabes Program Manager Visual C++ Microsoft Corporation

2 Vista Development Productivity Interoperability

3

4 Aero Aesthetics Common Controls Task Dialogs Search Wizards Common Dialogs Control Panels Icons System Font (Segoe UI) User Account Control Notifications Text and Tone Restart Manager Function Discovery Cancellable I/O Error Reporting API RSS Feeds Network Awareness Low-Rights IE ASLR

5 Hide/Unhide the Menu Bar New File Dialogs Support for the new Common Controls

6 New methods in CFrameWnd class to hide or show menu in an MFC Application Methods to dynamically toggle menu to become hidden or visible Event handlers for custom actions when menu is about to be hidden or visible. No support to toggle the menu bar in MDI and dialog-based applications virtual void CFrameWnd::SetMenuBarVisibility(DWORD nStyle); virtual DWORD CFrameWnd::GetMenuBarVisibility(); virtual void CFrameWnd::SetMenuBarVisibility(DWORD nStyle); virtual DWORD CFrameWnd::GetMenuBarVisibility();

7 By default, MFC applications compiled under VC2008 will utilize Vista-style dialogs on Vista New Methods Called The new MFC Common File Dialog uses IFileDialogEvents instead of OnNotify If the user runs the program in a pre-Vista OS, then the dialogs default to the old-style dialogs

8 Fell behind since Win9x. Now up-to-date New Control Messages New WM Messages New Controls like Pager Control Includes new Vista controls

9 Provides input and validation of IPv4, IPv6 and DNS names Wrapped in MFC by CNetAddressCtrl Network Address Control Large button with an optional icon and an optional note Wrapped in MFC by CButton Command Button Consolidates a set of variations of a command, especially when one of the commands is used most of the time Wrapped in MFC by CSplitButton Split Button

10

11 Updated Resource Editing New Controls Command Link, Net Address Ctrl, SysLink, Split Button Existing Controls Adding new styles, notifications, messages

12 Available out of the box Linker Switch /MANIFESTUAC Project Setting > Linker > Manifest File Project Upgrade UAC is turned on, level is set to “asInvoker”

13 Register COM components as normal user Put them into HKCU when developing Maintain existing deployment Support for debugging IE7 Protected Mode Debugger to Launch > Web Browser Debugger

14 Let’s review /GS /SafeSEH DEP New in Vista: ASLR Linker switch (/DYNAMICBASE) to opt in to support ASLR http://msdn2.microsoft.com/en-us/library/bb430720.aspx

15

16 Support for viewing PNG and Vista compressed icons Icon Editor Preview Area 256 px

17 In 2005 Build Multiple Project in Parallel Tools > Options > Project and Solutions > Build and Run > Parallel Project Builds In 2008 Build Multiple Translation Units in Parallel /MP or /MPn (where n is no. of CPUs) Project Properties > C/C++ > Command Line > Additional Options

18 A.Dll … ClassB b; b.f() … A.Dll … ClassB b; b.f() … B.Dll public ref class ClassB { public String f() { //important string here return “Important String”; } B.Dll public ref class ClassB { public String f() { //important string here return “Important String”; } A.dll B.dll B.meta B.meta(*) Skip projects with no “significant” changes since last build

19

20 New library to simplify passing data between native and managed code Template-based pattern that applies to any kind of data Support lots of types out-of-the-box System::String^ const char * System::String^ const wchar_t * System::String^ char * System::String^ wchar_t * System::IntPtr HANDLE System::String^ BSTR System::String^ bstr_t System::String^ std::string System::String^ std::wstring System::String^ ATL::CStringT System::String^ ATL::CStringT System::String^ CComBSTR

21 I want to marshal between managed and native data types for conversions that do not require any lifetime management or complex resource allocation #include using namespace msclr::interop; … { … const char* sourcestring1 = “teststring” System::String^ deststring1; // Convert const char* to System::String^ using // TO to = marshal_as (from) deststring1 = marshal_as (sourcestring1); … } #include using namespace msclr::interop; … { … const char* sourcestring1 = “teststring” System::String^ deststring1; // Convert const char* to System::String^ using // TO to = marshal_as (from) deststring1 = marshal_as (sourcestring1); … }

22 I want to marshal between managed and native data types for conversions that require some kind of lifetime (memory, resource, etc…) #include using namespace msclr::interop; … { … System::String^ sourcestring1 = “teststring” const char* deststring1; //Convert System::String^ to const char* using //TO to = context.marshal_as (from) marshal_context ctx; deststring1 = ctx.marshal_as (sourcestring1); … } #include using namespace msclr::interop; … { … System::String^ sourcestring1 = “teststring” const char* deststring1; //Convert System::String^ to const char* using //TO to = context.marshal_as (from) marshal_context ctx; deststring1 = ctx.marshal_as (sourcestring1); … }

23 Leverage STL skills in applications that use.NET Framework Ease data exchange between STL and.NET Collections The power of templates and generics together Designed to achieve optimal performance and cross-language compatibility STL in any part of managed code (but only C++)

24

25 Only does visualization of code

26 Me – http://blogs.msdn.com/borisjhttp://blogs.msdn.com/borisj VC++ - http://blogs.msdn.com/vcbloghttp://blogs.msdn.com/vcblog

27


Download ppt "Boris Jabes Program Manager Visual C++ Microsoft Corporation."

Similar presentations


Ads by Google