Sha256: ffeb5732e43560eec473e05678ab80d16fb3162300c66247bb092438599e83cd
Contents?: true
Size: 1.9 KB
Versions: 1
Compression:
Stored size: 1.9 KB
Contents
require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') require 'win/gui/input' #require 'win/gui/window' module WinGuiMessageTest include WinTestApp include Win::Gui::Message describe Win::Gui::Message do describe '#post_message' do spec{ use{ success = PostMessage(handle = 0, msg = 0, w_param = 0, l_param = 0) }} spec{ use{ success = post_message(handle = 0, msg = 0, w_param = 0, l_param = 0) }} it 'places (posts) a message in the message queue associated with the thread that created the specified window' it 'returns without waiting for the thread to process the message' end describe '#send_message' do spec{ use{ success = SendMessage(handle = 0, msg = 0, w_param = 1024, l_param = "\x0"*1024) }} spec{ use{ success = send_message(handle = 0, msg = 0, w_param = 1024, l_param = "\x0"*1024) }} # handle (L) - Handle to the window whose window procedure is to receive the message. The following values have special meanings. # HWND_BROADCAST - The message is posted to all top-level windows in the system, including disabled or invisible unowned windows, # overlapped windows, and pop-up windows. The message is not posted to child windows. # NULL - The function behaves like a call to PostThreadMessage with the dwThreadId parameter set to the identifier of the current thread. # msg (L) - Specifies the message to be posted. # w_param (L) - Specifies additional message-specific information. # l_param (L) - Specifies additional message-specific information. # return (L) - Nonzero if success, zero if function failed. To get extended error information, call GetLastError. it 'sends the specified message to a window or windows' it 'calls the window procedure and does not return until the window procedure has processed the message' end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
win-0.1.9 | spec/win/gui/message_spec.rb |