testing and doxy comment audio and screen
This commit is contained in:
parent
e31616e5dd
commit
f4ceafbe6c
@ -4,7 +4,10 @@
|
||||
#include <nana/deploy.hpp>
|
||||
|
||||
namespace nana{ namespace audio
|
||||
{ /// play an audio file in Windows WAV format
|
||||
{ /// class player
|
||||
/// \brief play an audio file in PCM Windows WAV format
|
||||
///
|
||||
/// \include audio_player.cpp
|
||||
class player
|
||||
: private nana::noncopyable
|
||||
{
|
||||
|
@ -34,27 +34,38 @@ namespace nana
|
||||
virtual const ::nana::rectangle& workarea() const = 0;
|
||||
};
|
||||
|
||||
/// Provides some functions to get the metrics of the monitors \include screen.cpp
|
||||
class screen
|
||||
{
|
||||
struct implement;
|
||||
public:
|
||||
static ::nana::size desktop_size();
|
||||
static ::nana::size primary_monitor_size();
|
||||
/// gets the size in pixel of the whole virtual desktop
|
||||
static ::nana::size desktop_size();
|
||||
|
||||
/// gets the resolution in pixel of the primary monitor,
|
||||
/// if there is only one monitor installed in the system,
|
||||
/// the return value of primary_monitor_size is equal to desktop_size's.
|
||||
static ::nana::size primary_monitor_size();
|
||||
|
||||
|
||||
screen();
|
||||
|
||||
/// Reload has no preconditions, it's safe to call on moved-from
|
||||
void reload();
|
||||
|
||||
/// Returns the number of display monitors
|
||||
/// Returns the number of display monitors installed in the system
|
||||
std::size_t count() const;
|
||||
|
||||
/// gets the display monitor that contains the specified point
|
||||
display& from_point(const point&);
|
||||
|
||||
/// gets the display monitor that contains the specified window
|
||||
display& from_window(window);
|
||||
|
||||
display& get_display(std::size_t index) const;
|
||||
display& get_primary() const;
|
||||
|
||||
/// applies a given function to all display monitors
|
||||
void for_each(std::function<void(display&)>) const;
|
||||
private:
|
||||
std::shared_ptr<implement> impl_;
|
||||
|
@ -8,7 +8,8 @@ namespace nana{ namespace audio
|
||||
//class audio_stream
|
||||
bool audio_stream::open(const nana::string& file)
|
||||
{
|
||||
fs_.open(static_cast<std::string>(nana::charset(file)), std::ios::binary);
|
||||
std::string fname{nana::charset(file)};//static_cast<std::string>()
|
||||
fs_.open(fname, std::ios::binary);
|
||||
if(fs_)
|
||||
{
|
||||
wave_spec::master_riff_chunk riff;
|
||||
|
Loading…
x
Reference in New Issue
Block a user