comp.lang.ada
 help / color / mirror / Atom feed
From: alby.gamper@gmail.com
Subject: Microsoft UWP/WinRt
Date: Thu, 1 Jun 2017 18:23:39 -0700 (PDT)
Date: 2017-06-01T18:23:39-07:00	[thread overview]
Message-ID: <7d1796c7-3492-4f19-ac6c-27c70e486d59@googlegroups.com> (raw)

Hello Ada community

Would anyone be interested in a set of Ada bindings to the new Microsoft
UWP/WinRT api ?. This would enable Ada to be used to develop native Windows Store
applications and also allow parts of the Api to be used from Desktop applications
as well. (Note, as documented by Microsoft, only a subset of the WinRT api can
be used by traditional desktop applications)

Below is a very simple sample of what the bindings would look like

procedure Test4 is

			procedure ConnectAsync_Callback (asyncInfo : Windows.Foundation.IAsyncAction ; asyncStatus : Windows.Foundation.AsyncStatus) is
				Hr			: Windows.HRESULT := 0;
				m_RetVal	: aliased Windows.Void;
			begin
				Hr := asyncInfo.GetResults(m_RetVal'access);
				Put_Line("Callback Invoked - connected to www.microsoft.com");
			end;

			Hr						: Windows.HRESULT := 0;
			m_RetVal				: aliased Windows.Void;
			m_HostNameFactory		: HostNameFactory;
			m_IHostName				: IHostName;
			m_StreamSocket			: StreamSocket;
			m_IAsyncAction			: IAsyncAction;						
			m_AsyncActionCompleted	: AsyncActionCompletedHandler := new AsyncActionCompletedHandler_Interface(ConnectAsync_Callback'access);

		begin
			m_IHostName := m_HostNameFactory.CreateHostName(To_String("www.microsoft.com"));
			m_IAsyncAction := m_StreamSocket.ConnectAsync(m_IHostName, To_String("http"));
			Hr := m_IAsyncAction.put_Completed(m_AsyncActionCompleted, m_RetVal'access);
			delay 5.0;
			m_StreamSocket.Close;
		end;

             reply	other threads:[~2017-06-02  1:23 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-02  1:23 alby.gamper [this message]
2017-06-02  7:24 ` Microsoft UWP/WinRt Dmitry A. Kazakov
2017-06-02 12:27   ` Lucretia
2017-06-02 13:28     ` Dmitry A. Kazakov
2017-06-02 14:53       ` gautier_niouzes
2017-06-02 14:56         ` Dmitry A. Kazakov
2017-06-02 21:11         ` Randy Brukardt
2017-06-08 15:31     ` Pascal Obry
2017-06-14  5:43       ` Microsoft UWP/WinRT - Update alby.gamper
2017-06-18  1:15         ` Ivan Levashev
2017-06-18  2:03       ` JEDI, Win32Ada and GNAT-COM Ivan Levashev
2017-07-03 10:14         ` Luke A. Guest
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox