Merge branch 'bugfix/doc_n_spaces'

This commit is contained in:
Lukas Dürrenberger 2014-11-19 10:11:46 +01:00
commit 188f713900
83 changed files with 224 additions and 224 deletions

View File

@ -59,7 +59,7 @@ macro(sfml_add_library target)
endif() endif()
# if using gcc >= 4.0 or clang >= 3.0 on a non-Windows platform, we must hide public symbols by default # if using gcc >= 4.0 or clang >= 3.0 on a non-Windows platform, we must hide public symbols by default
# (exported ones are explicitely marked) # (exported ones are explicitly marked)
if(NOT SFML_OS_WINDOWS AND ((SFML_COMPILER_GCC AND NOT SFML_GCC_VERSION VERSION_LESS "4") OR (SFML_COMPILER_CLANG AND NOT SFML_CLANG_VERSION VERSION_LESS "3"))) if(NOT SFML_OS_WINDOWS AND ((SFML_COMPILER_GCC AND NOT SFML_GCC_VERSION VERSION_LESS "4") OR (SFML_COMPILER_CLANG AND NOT SFML_CLANG_VERSION VERSION_LESS "3")))
set_target_properties(${target} PROPERTIES COMPILE_FLAGS -fvisibility=hidden) set_target_properties(${target} PROPERTIES COMPILE_FLAGS -fvisibility=hidden)
endif() endif()

View File

@ -10,7 +10,7 @@
# find_package(SFML COMPONENTS graphics window system) // find the graphics, window and system modules # find_package(SFML COMPONENTS graphics window system) // find the graphics, window and system modules
# #
# You can enforce a specific version, either MAJOR.MINOR or only MAJOR. # You can enforce a specific version, either MAJOR.MINOR or only MAJOR.
# If nothing is specified, the version won't be checked (ie. any version will be accepted). # If nothing is specified, the version won't be checked (i.e. any version will be accepted).
# example: # example:
# find_package(SFML COMPONENTS ...) // no specific version required # find_package(SFML COMPONENTS ...) // no specific version required
# find_package(SFML 2 COMPONENTS ...) // any 2.x version # find_package(SFML 2 COMPONENTS ...) // any 2.x version

View File

@ -64,7 +64,7 @@
-(std::wstring)tostdwstring -(std::wstring)tostdwstring
{ {
// According to wikipedia, Mac OS X is Little Endian on x86 and x86-64 // According to Wikipedia, Mac OS X is Little Endian on x86 and x86-64
// http://en.wikipedia.org/wiki/Endianness // http://en.wikipedia.org/wiki/Endianness
NSData* asData = [self dataUsingEncoding:NSUTF32LittleEndianStringEncoding]; NSData* asData = [self dataUsingEncoding:NSUTF32LittleEndianStringEncoding];
return std::wstring((wchar_t*)[asData bytes], [asData length] / sizeof(wchar_t)); return std::wstring((wchar_t*)[asData bytes], [asData length] / sizeof(wchar_t));

View File

@ -93,7 +93,7 @@ public:
/// w64, mat4, mat5 pvf, htk, sds, avr, sd2, caf, wve, mpc2k, rf64. /// w64, mat4, mat5 pvf, htk, sds, avr, sd2, caf, wve, mpc2k, rf64.
/// Since the music is not loaded completely but rather streamed /// Since the music is not loaded completely but rather streamed
/// continuously, the \a data must remain available as long as the /// continuously, the \a data must remain available as long as the
/// music is playing (ie. you can't deallocate it right after calling /// music is playing (i.e. you can't deallocate it right after calling
/// this function). /// this function).
/// ///
/// \param data Pointer to the file data in memory /// \param data Pointer to the file data in memory
@ -116,7 +116,7 @@ public:
/// w64, mat4, mat5 pvf, htk, sds, avr, sd2, caf, wve, mpc2k, rf64. /// w64, mat4, mat5 pvf, htk, sds, avr, sd2, caf, wve, mpc2k, rf64.
/// Since the music is not loaded completely but rather streamed /// Since the music is not loaded completely but rather streamed
/// continuously, the \a stream must remain alive as long as the /// continuously, the \a stream must remain alive as long as the
/// music is playing (ie. you can't destroy it right after calling /// music is playing (i.e. you can't destroy it right after calling
/// this function). /// this function).
/// ///
/// \param stream Source stream to read from /// \param stream Source stream to read from
@ -186,13 +186,13 @@ private:
/// \class sf::Music /// \class sf::Music
/// \ingroup audio /// \ingroup audio
/// ///
/// Musics are sounds that are streamed rather than completely /// Music objects are sounds that are streamed rather than
/// loaded in memory. This is especially useful for compressed /// completely loaded in memory. This is especially useful for
/// musics that usually take hundreds of MB when they are /// compressed music that usually takes hundreds of MB when it is
/// uncompressed: by streaming it instead of loading it entirely, /// uncompressed: by streaming it instead of loading it entirely,
/// you avoid saturating the memory and have almost no loading delay. /// you avoid saturating the memory and have almost no loading delay.
/// ///
/// Apart from that, a sf::Music has almost the same features as /// Apart from that, sf::Music has almost the same features as
/// the sf::SoundBuffer / sf::Sound pair: you can play/pause/stop /// the sf::SoundBuffer / sf::Sound pair: you can play/pause/stop
/// it, request its parameters (channels, sample rate), change /// it, request its parameters (channels, sample rate), change
/// the way it is played (pitch, volume, 3D position, ...), etc. /// the way it is played (pitch, volume, 3D position, ...), etc.

View File

@ -146,7 +146,7 @@ public:
/// The playing position can be changed when the sound is /// The playing position can be changed when the sound is
/// either paused or playing. Changing the playing position /// either paused or playing. Changing the playing position
/// when the sound is stopped has no effect, since playing /// when the sound is stopped has no effect, since playing
/// the sound would reset its position. /// the sound will reset its position.
/// ///
/// \param timeOffset New playing position, from the beginning of the sound /// \param timeOffset New playing position, from the beginning of the sound
/// ///

View File

@ -96,10 +96,10 @@ public:
unsigned int getSampleRate() const; unsigned int getSampleRate() const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Get a list of the names of all availabe audio capture devices /// \brief Get a list of the names of all available audio capture devices
/// ///
/// This function returns a vector of strings, containing /// This function returns a vector of strings, containing
/// the names of all availabe audio capture devices. /// the names of all available audio capture devices.
/// ///
/// \return A vector of strings containing the names /// \return A vector of strings containing the names
/// ///
@ -187,7 +187,7 @@ protected:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Start capturing audio data /// \brief Start capturing audio data
/// ///
/// This virtual function may be overriden by a derived class /// This virtual function may be overridden by a derived class
/// if something has to be done every time a new capture /// if something has to be done every time a new capture
/// starts. If not, this function can be ignored; the default /// starts. If not, this function can be ignored; the default
/// implementation does nothing. /// implementation does nothing.
@ -216,7 +216,7 @@ protected:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Stop capturing audio data /// \brief Stop capturing audio data
/// ///
/// This virtual function may be overriden by a derived class /// This virtual function may be overridden by a derived class
/// if something has to be done every time the capture /// if something has to be done every time the capture
/// ends. If not, this function can be ignored; the default /// ends. If not, this function can be ignored; the default
/// implementation does nothing. /// implementation does nothing.
@ -285,7 +285,7 @@ private:
/// A derived class has only one virtual function to override: /// A derived class has only one virtual function to override:
/// \li onProcessSamples provides the new chunks of audio samples while the capture happens /// \li onProcessSamples provides the new chunks of audio samples while the capture happens
/// ///
/// Moreover, two additionnal virtual functions can be overriden /// Moreover, two additional virtual functions can be overridden
/// as well if necessary: /// as well if necessary:
/// \li onStart is called before the capture happens, to perform custom initializations /// \li onStart is called before the capture happens, to perform custom initializations
/// \li onStop is called after the capture ends, to perform custom cleanup /// \li onStop is called after the capture ends, to perform custom cleanup
@ -303,9 +303,9 @@ private:
/// ///
/// If you have multiple sound input devices connected to your /// If you have multiple sound input devices connected to your
/// computer (for example: microphone, external soundcard, webcam mic, ...) /// computer (for example: microphone, external soundcard, webcam mic, ...)
/// you can get a list of all available devices throught the /// you can get a list of all available devices through the
/// getAvailableDevices() function. You can then select a device /// getAvailableDevices() function. You can then select a device
/// by calling setDevice() with the appropiate device. Otherwise /// by calling setDevice() with the appropriate device. Otherwise
/// the default capturing device will be used. /// the default capturing device will be used.
/// ///
/// It is important to note that the audio capture happens in a /// It is important to note that the audio capture happens in a

View File

@ -130,7 +130,7 @@ public:
/// \brief Make the sound's position relative to the listener or absolute /// \brief Make the sound's position relative to the listener or absolute
/// ///
/// Making a sound relative to the listener will ensure that it will always /// Making a sound relative to the listener will ensure that it will always
/// be played the same way regardless the position of the listener. /// be played the same way regardless of the position of the listener.
/// This can be useful for non-spatialized sounds, sounds that are /// This can be useful for non-spatialized sounds, sounds that are
/// produced by the listener, or sounds attached to it. /// produced by the listener, or sounds attached to it.
/// The default value is false (position is absolute). /// The default value is false (position is absolute).
@ -244,7 +244,7 @@ protected:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Default constructor /// \brief Default constructor
/// ///
/// This constructor is meant ot be called by derived classes only. /// This constructor is meant to be called by derived classes only.
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
SoundSource(); SoundSource();

View File

@ -207,7 +207,7 @@ protected:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Request a new chunk of audio samples from the stream source /// \brief Request a new chunk of audio samples from the stream source
/// ///
/// This function must be overriden by derived classes to provide /// This function must be overridden by derived classes to provide
/// the audio samples to play. It is called continuously by the /// the audio samples to play. It is called continuously by the
/// streaming loop, in a separate thread. /// streaming loop, in a separate thread.
/// The source can choose to stop the streaming loop at any time, by /// The source can choose to stop the streaming loop at any time, by
@ -226,7 +226,7 @@ protected:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Change the current playing position in the stream source /// \brief Change the current playing position in the stream source
/// ///
/// This function must be overriden by derived classes to /// This function must be overridden by derived classes to
/// allow random seeking into the stream source. /// allow random seeking into the stream source.
/// ///
/// \param timeOffset New playing position, relative to the beginning of the stream /// \param timeOffset New playing position, relative to the beginning of the stream
@ -313,7 +313,7 @@ private:
/// Unlike audio buffers (see sf::SoundBuffer), audio streams /// Unlike audio buffers (see sf::SoundBuffer), audio streams
/// are never completely loaded in memory. Instead, the audio /// are never completely loaded in memory. Instead, the audio
/// data is acquired continuously while the stream is playing. /// data is acquired continuously while the stream is playing.
/// This behaviour allows to play a sound with no loading delay, /// This behavior allows to play a sound with no loading delay,
/// and keeps the memory consumption very low. /// and keeps the memory consumption very low.
/// ///
/// Sound sources that need to be streamed are usually big files /// Sound sources that need to be streamed are usually big files

View File

@ -34,7 +34,7 @@
namespace sf namespace sf
{ {
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Utility class for manpulating RGBA colors /// \brief Utility class for manipulating RGBA colors
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
class SFML_GRAPHICS_API Color class SFML_GRAPHICS_API Color

View File

@ -51,7 +51,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
// Member data // Member data
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
float advance; ///< Offset to move horizontically to the next character float advance; ///< Offset to move horizontally to the next character
FloatRect bounds; ///< Bounding rectangle of the glyph, in coordinates relative to the baseline FloatRect bounds; ///< Bounding rectangle of the glyph, in coordinates relative to the baseline
IntRect textureRect; ///< Texture coordinates of the glyph inside the font's texture IntRect textureRect; ///< Texture coordinates of the glyph inside the font's texture
}; };

View File

@ -76,7 +76,7 @@ public:
/// ///
/// The \a pixel array is assumed to contain 32-bits RGBA pixels, /// The \a pixel array is assumed to contain 32-bits RGBA pixels,
/// and have the given \a width and \a height. If not, this is /// and have the given \a width and \a height. If not, this is
/// an undefined behaviour. /// an undefined behavior.
/// If \a pixels is null, an empty image is created. /// If \a pixels is null, an empty image is created.
/// ///
/// \param width Width of the image /// \param width Width of the image
@ -203,7 +203,7 @@ public:
/// ///
/// This function doesn't check the validity of the pixel /// This function doesn't check the validity of the pixel
/// coordinates, using out-of-range values will result in /// coordinates, using out-of-range values will result in
/// an undefined behaviour. /// an undefined behavior.
/// ///
/// \param x X coordinate of pixel to change /// \param x X coordinate of pixel to change
/// \param y Y coordinate of pixel to change /// \param y Y coordinate of pixel to change
@ -219,7 +219,7 @@ public:
/// ///
/// This function doesn't check the validity of the pixel /// This function doesn't check the validity of the pixel
/// coordinates, using out-of-range values will result in /// coordinates, using out-of-range values will result in
/// an undefined behaviour. /// an undefined behavior.
/// ///
/// \param x X coordinate of pixel to get /// \param x X coordinate of pixel to get
/// \param y Y coordinate of pixel to get /// \param y Y coordinate of pixel to get

View File

@ -32,7 +32,7 @@ namespace sf
/// \brief Types of primitives that a sf::VertexArray can render /// \brief Types of primitives that a sf::VertexArray can render
/// ///
/// Points and lines have no area, therefore their thickness /// Points and lines have no area, therefore their thickness
/// will always be 1 pixel, regarldess the current transform /// will always be 1 pixel, regardless the current transform
/// and view. /// and view.
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////

View File

@ -219,7 +219,7 @@ typedef Rect<float> FloatRect;
/// don't intersect. /// don't intersect.
/// ///
/// sf::Rect is a template and may be used with any numeric type, but /// sf::Rect is a template and may be used with any numeric type, but
/// for simplicity the instanciations used by SFML are typedefed: /// for simplicity the instantiations used by SFML are typedef'd:
/// \li sf::Rect<int> is sf::IntRect /// \li sf::Rect<int> is sf::IntRect
/// \li sf::Rect<float> is sf::FloatRect /// \li sf::Rect<float> is sf::FloatRect
/// ///

View File

@ -147,7 +147,7 @@ public:
/// on top of each object's transform. /// on top of each object's transform.
/// ///
/// Most objects, especially high-level drawables, can be drawn /// Most objects, especially high-level drawables, can be drawn
/// directly without defining render states explicitely -- the /// directly without defining render states explicitly -- the
/// default set of states is ok in most cases. /// default set of states is ok in most cases.
/// \code /// \code
/// window.Draw(sprite); /// window.Draw(sprite);

View File

@ -74,7 +74,7 @@ public:
/// ///
/// The view is like a 2D camera, it controls which part of /// The view is like a 2D camera, it controls which part of
/// the 2D scene is visible, and how it is viewed in the /// the 2D scene is visible, and how it is viewed in the
/// render-target. /// render target.
/// The new view will affect everything that is drawn, until /// The new view will affect everything that is drawn, until
/// another view is set. /// another view is set.
/// The render target keeps its own copy of the view object, /// The render target keeps its own copy of the view object,
@ -133,7 +133,7 @@ public:
/// coordinates, using the current view /// coordinates, using the current view
/// ///
/// This function is an overload of the mapPixelToCoords /// This function is an overload of the mapPixelToCoords
/// function that implicitely uses the current view. /// function that implicitly uses the current view.
/// It is equivalent to: /// It is equivalent to:
/// \code /// \code
/// target.mapPixelToCoords(point, target.getView()); /// target.mapPixelToCoords(point, target.getView());
@ -152,14 +152,14 @@ public:
/// \brief Convert a point from target coordinates to world coordinates /// \brief Convert a point from target coordinates to world coordinates
/// ///
/// This function finds the 2D position that matches the /// This function finds the 2D position that matches the
/// given pixel of the render-target. In other words, it does /// given pixel of the render target. In other words, it does
/// the inverse of what the graphics card does, to find the /// the inverse of what the graphics card does, to find the
/// initial position of a rendered pixel. /// initial position of a rendered pixel.
/// ///
/// Initially, both coordinate systems (world units and target pixels) /// Initially, both coordinate systems (world units and target pixels)
/// match perfectly. But if you define a custom view or resize your /// match perfectly. But if you define a custom view or resize your
/// render-target, this assertion is not true anymore, ie. a point /// render target, this assertion is not true anymore, i.e. a point
/// located at (10, 50) in your render-target may map to the point /// located at (10, 50) in your render target may map to the point
/// (150, 75) in your 2D world -- if the view is translated by (140, 25). /// (150, 75) in your 2D world -- if the view is translated by (140, 25).
/// ///
/// For render-windows, this function is typically used to find /// For render-windows, this function is typically used to find
@ -167,7 +167,7 @@ public:
/// ///
/// This version uses a custom view for calculations, see the other /// This version uses a custom view for calculations, see the other
/// overload of the function if you want to use the current view of the /// overload of the function if you want to use the current view of the
/// render-target. /// render target.
/// ///
/// \param point Pixel to convert /// \param point Pixel to convert
/// \param view The view to use for converting the point /// \param view The view to use for converting the point
@ -184,7 +184,7 @@ public:
/// coordinates, using the current view /// coordinates, using the current view
/// ///
/// This function is an overload of the mapCoordsToPixel /// This function is an overload of the mapCoordsToPixel
/// function that implicitely uses the current view. /// function that implicitly uses the current view.
/// It is equivalent to: /// It is equivalent to:
/// \code /// \code
/// target.mapCoordsToPixel(point, target.getView()); /// target.mapCoordsToPixel(point, target.getView());
@ -202,19 +202,19 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Convert a point from world coordinates to target coordinates /// \brief Convert a point from world coordinates to target coordinates
/// ///
/// This function finds the pixel of the render-target that matches /// This function finds the pixel of the render target that matches
/// the given 2D point. In other words, it goes through the same process /// the given 2D point. In other words, it goes through the same process
/// as the graphics card, to compute the final position of a rendered point. /// as the graphics card, to compute the final position of a rendered point.
/// ///
/// Initially, both coordinate systems (world units and target pixels) /// Initially, both coordinate systems (world units and target pixels)
/// match perfectly. But if you define a custom view or resize your /// match perfectly. But if you define a custom view or resize your
/// render-target, this assertion is not true anymore, ie. a point /// render target, this assertion is not true anymore, i.e. a point
/// located at (150, 75) in your 2D world may map to the pixel /// located at (150, 75) in your 2D world may map to the pixel
/// (10, 50) of your render-target -- if the view is translated by (140, 25). /// (10, 50) of your render target -- if the view is translated by (140, 25).
/// ///
/// This version uses a custom view for calculations, see the other /// This version uses a custom view for calculations, see the other
/// overload of the function if you want to use the current view of the /// overload of the function if you want to use the current view of the
/// render-target. /// render target.
/// ///
/// \param point Point to convert /// \param point Point to convert
/// \param view The view to use for converting the point /// \param view The view to use for converting the point
@ -227,7 +227,7 @@ public:
Vector2i mapCoordsToPixel(const Vector2f& point, const View& view) const; Vector2i mapCoordsToPixel(const Vector2f& point, const View& view) const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Draw a drawable object to the render-target /// \brief Draw a drawable object to the render target
/// ///
/// \param drawable Object to draw /// \param drawable Object to draw
/// \param states Render states to use for drawing /// \param states Render states to use for drawing
@ -259,7 +259,7 @@ public:
/// \brief Save the current OpenGL render states and matrices /// \brief Save the current OpenGL render states and matrices
/// ///
/// This function can be used when you mix SFML drawing /// This function can be used when you mix SFML drawing
/// and direct OpenGL rendering. Combined with PopGLStates, /// and direct OpenGL rendering. Combined with popGLStates,
/// it ensures that: /// it ensures that:
/// \li SFML's internal states are not messed up by your OpenGL code /// \li SFML's internal states are not messed up by your OpenGL code
/// \li your OpenGL states are not modified by a call to a SFML function /// \li your OpenGL states are not modified by a call to a SFML function
@ -281,7 +281,7 @@ public:
/// It is provided for convenience, but the best results will /// It is provided for convenience, but the best results will
/// be achieved if you handle OpenGL states yourself (because /// be achieved if you handle OpenGL states yourself (because
/// you know which states have really changed, and need to be /// you know which states have really changed, and need to be
/// saved and restored). Take a look at the ResetGLStates /// saved and restored). Take a look at the resetGLStates
/// function if you do so. /// function if you do so.
/// ///
/// \see popGLStates /// \see popGLStates
@ -428,7 +428,7 @@ private:
/// \class sf::RenderTarget /// \class sf::RenderTarget
/// \ingroup graphics /// \ingroup graphics
/// ///
/// sf::RenderTarget defines the common behaviour of all the /// sf::RenderTarget defines the common behavior of all the
/// 2D render targets usable in the graphics module. It makes /// 2D render targets usable in the graphics module. It makes
/// it possible to draw 2D entities like sprites, shapes, text /// it possible to draw 2D entities like sprites, shapes, text
/// without using any OpenGL command directly. /// without using any OpenGL command directly.

View File

@ -73,7 +73,7 @@ public:
/// doing anything with the render-texture. /// doing anything with the render-texture.
/// The last parameter, \a depthBuffer, is useful if you want /// The last parameter, \a depthBuffer, is useful if you want
/// to use the render-texture for 3D OpenGL rendering that requires /// to use the render-texture for 3D OpenGL rendering that requires
/// a depth-buffer. Otherwise it is unnecessary, and you should /// a depth buffer. Otherwise it is unnecessary, and you should
/// leave this parameter to false (which is its default value). /// leave this parameter to false (which is its default value).
/// ///
/// \param width Width of the render-texture /// \param width Width of the render-texture

View File

@ -59,7 +59,7 @@ public:
/// ///
/// This constructor creates the window with the size and pixel /// This constructor creates the window with the size and pixel
/// depth defined in \a mode. An optional style can be passed to /// depth defined in \a mode. An optional style can be passed to
/// customize the look and behaviour of the window (borders, /// customize the look and behavior of the window (borders,
/// title bar, resizable, closable, ...). /// title bar, resizable, closable, ...).
/// ///
/// The fourth parameter is an optional structure specifying /// The fourth parameter is an optional structure specifying

View File

@ -59,7 +59,7 @@ public:
/// doesn't store its own copy of the texture, but rather keeps /// doesn't store its own copy of the texture, but rather keeps
/// a pointer to the one that you passed to this function. /// a pointer to the one that you passed to this function.
/// If the source texture is destroyed and the shape tries to /// If the source texture is destroyed and the shape tries to
/// use it, the behaviour is undefined. /// use it, the behavior is undefined.
/// \a texture can be NULL to disable texturing. /// \a texture can be NULL to disable texturing.
/// If \a resetRect is true, the TextureRect property of /// If \a resetRect is true, the TextureRect property of
/// the shape is automatically adjusted to the size of the new /// the shape is automatically adjusted to the size of the new
@ -252,7 +252,7 @@ protected:
/// \brief Recompute the internal geometry of the shape /// \brief Recompute the internal geometry of the shape
/// ///
/// This function must be called by the derived class everytime /// This function must be called by the derived class everytime
/// the shape's points change (ie. the result of either /// the shape's points change (i.e. the result of either
/// getPointCount or getPoint is different). /// getPointCount or getPoint is different).
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////

View File

@ -85,7 +85,7 @@ public:
/// doesn't store its own copy of the texture, but rather keeps /// doesn't store its own copy of the texture, but rather keeps
/// a pointer to the one that you passed to this function. /// a pointer to the one that you passed to this function.
/// If the source texture is destroyed and the sprite tries to /// If the source texture is destroyed and the sprite tries to
/// use it, the behaviour is undefined. /// use it, the behavior is undefined.
/// If \a resetRect is true, the TextureRect property of /// If \a resetRect is true, the TextureRect property of
/// the sprite is automatically adjusted to the size of the new /// the sprite is automatically adjusted to the size of the new
/// texture. If it is false, the texture rect is left unchanged. /// texture. If it is false, the texture rect is left unchanged.

View File

@ -116,7 +116,7 @@ public:
/// doesn't store its own copy of the font, but rather keeps /// doesn't store its own copy of the font, but rather keeps
/// a pointer to the one that you passed to this function. /// a pointer to the one that you passed to this function.
/// If the font is destroyed and the text tries to /// If the font is destroyed and the text tries to
/// use it, the behaviour is undefined. /// use it, the behavior is undefined.
/// ///
/// \param font New font /// \param font New font
/// ///
@ -193,7 +193,7 @@ public:
/// \brief Get the text's font /// \brief Get the text's font
/// ///
/// If the text has no font attached, a NULL pointer is returned. /// If the text has no font attached, a NULL pointer is returned.
/// The returned reference is const, which means that you /// The returned pointer is const, which means that you
/// cannot modify the font when you get it from this function. /// cannot modify the font when you get it from this function.
/// ///
/// \return Pointer to the text's font /// \return Pointer to the text's font

View File

@ -244,7 +244,7 @@ public:
/// ///
/// No additional check is performed on the size of the pixel /// No additional check is performed on the size of the pixel
/// array, passing invalid arguments will lead to an undefined /// array, passing invalid arguments will lead to an undefined
/// behaviour. /// behavior.
/// ///
/// This function does nothing if \a pixels is null or if the /// This function does nothing if \a pixels is null or if the
/// texture was not previously created. /// texture was not previously created.
@ -262,7 +262,7 @@ public:
/// ///
/// No additional check is performed on the size of the pixel /// No additional check is performed on the size of the pixel
/// array or the bounds of the area to update, passing invalid /// array or the bounds of the area to update, passing invalid
/// arguments will lead to an undefined behaviour. /// arguments will lead to an undefined behavior.
/// ///
/// This function does nothing if \a pixels is null or if the /// This function does nothing if \a pixels is null or if the
/// texture was not previously created. /// texture was not previously created.
@ -286,7 +286,7 @@ public:
/// ///
/// No additional check is performed on the size of the image, /// No additional check is performed on the size of the image,
/// passing an image bigger than the texture will lead to an /// passing an image bigger than the texture will lead to an
/// undefined behaviour. /// undefined behavior.
/// ///
/// This function does nothing if the texture was not /// This function does nothing if the texture was not
/// previously created. /// previously created.
@ -301,7 +301,7 @@ public:
/// ///
/// No additional check is performed on the size of the image, /// No additional check is performed on the size of the image,
/// passing an invalid combination of image size and offset /// passing an invalid combination of image size and offset
/// will lead to an undefined behaviour. /// will lead to an undefined behavior.
/// ///
/// This function does nothing if the texture was not /// This function does nothing if the texture was not
/// previously created. /// previously created.
@ -323,7 +323,7 @@ public:
/// ///
/// No additional check is performed on the size of the window, /// No additional check is performed on the size of the window,
/// passing a window bigger than the texture will lead to an /// passing a window bigger than the texture will lead to an
/// undefined behaviour. /// undefined behavior.
/// ///
/// This function does nothing if either the texture or the window /// This function does nothing if either the texture or the window
/// was not previously created. /// was not previously created.
@ -338,7 +338,7 @@ public:
/// ///
/// No additional check is performed on the size of the window, /// No additional check is performed on the size of the window,
/// passing an invalid combination of window size and offset /// passing an invalid combination of window size and offset
/// will lead to an undefined behaviour. /// will lead to an undefined behavior.
/// ///
/// This function does nothing if either the texture or the window /// This function does nothing if either the texture or the window
/// was not previously created. /// was not previously created.

View File

@ -75,7 +75,7 @@ public:
/// \brief Get a read-write access to a vertex by its index /// \brief Get a read-write access to a vertex by its index
/// ///
/// This function doesn't check \a index, it must be in range /// This function doesn't check \a index, it must be in range
/// [0, getVertexCount() - 1]. The behaviour is undefined /// [0, getVertexCount() - 1]. The behavior is undefined
/// otherwise. /// otherwise.
/// ///
/// \param index Index of the vertex to get /// \param index Index of the vertex to get
@ -91,7 +91,7 @@ public:
/// \brief Get a read-only access to a vertex by its index /// \brief Get a read-only access to a vertex by its index
/// ///
/// This function doesn't check \a index, it must be in range /// This function doesn't check \a index, it must be in range
/// [0, getVertexCount() - 1]. The behaviour is undefined /// [0, getVertexCount() - 1]. The behavior is undefined
/// otherwise. /// otherwise.
/// ///
/// \param index Index of the vertex to get /// \param index Index of the vertex to get

View File

@ -216,7 +216,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Specialization of FTP response returning a /// \brief Specialization of FTP response returning a
/// filename lisiting /// filename listing
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
class SFML_NETWORK_API ListingResponse : public Response class SFML_NETWORK_API ListingResponse : public Response
{ {

View File

@ -85,7 +85,7 @@ public:
/// \brief Set the value of a field /// \brief Set the value of a field
/// ///
/// The field is created if it doesn't exist. The name of /// The field is created if it doesn't exist. The name of
/// the field is case insensitive. /// the field is case-insensitive.
/// By default, a request doesn't contain any field (but the /// By default, a request doesn't contain any field (but the
/// mandatory fields are added later by the HTTP client when /// mandatory fields are added later by the HTTP client when
/// sending the request). /// sending the request).
@ -212,12 +212,12 @@ public:
MultipleChoices = 300, ///< The requested page can be accessed from several locations MultipleChoices = 300, ///< The requested page can be accessed from several locations
MovedPermanently = 301, ///< The requested page has permanently moved to a new location MovedPermanently = 301, ///< The requested page has permanently moved to a new location
MovedTemporarily = 302, ///< The requested page has temporarily moved to a new location MovedTemporarily = 302, ///< The requested page has temporarily moved to a new location
NotModified = 304, ///< For conditionnal requests, means the requested page hasn't changed and doesn't need to be refreshed NotModified = 304, ///< For conditional requests, means the requested page hasn't changed and doesn't need to be refreshed
// 4xx: client error // 4xx: client error
BadRequest = 400, ///< The server couldn't understand the request (syntax error) BadRequest = 400, ///< The server couldn't understand the request (syntax error)
Unauthorized = 401, ///< The requested page needs an authentification to be accessed Unauthorized = 401, ///< The requested page needs an authentication to be accessed
Forbidden = 403, ///< The requested page cannot be accessed at all, even with authentification Forbidden = 403, ///< The requested page cannot be accessed at all, even with authentication
NotFound = 404, ///< The requested page doesn't exist NotFound = 404, ///< The requested page doesn't exist
RangeNotSatisfiable = 407, ///< The server can't satisfy the partial GET request (with a "Range" header field) RangeNotSatisfiable = 407, ///< The server can't satisfy the partial GET request (with a "Range" header field)
@ -393,7 +393,7 @@ public:
/// Warning: this function waits for the server's response and may /// Warning: this function waits for the server's response and may
/// not return instantly; use a thread if you don't want to block your /// not return instantly; use a thread if you don't want to block your
/// application, or use a timeout to limit the time to wait. A value /// application, or use a timeout to limit the time to wait. A value
/// of Time::Zero means that the client will use the system defaut timeout /// of Time::Zero means that the client will use the system default timeout
/// (which is usually pretty long). /// (which is usually pretty long).
/// ///
/// \param request Request to send /// \param request Request to send

View File

@ -139,7 +139,7 @@ public:
/// A packet will be in an invalid state if it has no more /// A packet will be in an invalid state if it has no more
/// data to read. /// data to read.
/// ///
/// This behaviour is the same as standard C++ streams. /// This behavior is the same as standard C++ streams.
/// ///
/// Usage example: /// Usage example:
/// \code /// \code
@ -242,7 +242,7 @@ protected:
/// ///
/// This function can be defined by derived classes to /// This function can be defined by derived classes to
/// transform the data after it is received; this can be /// transform the data after it is received; this can be
/// used for uncompression, decryption, etc. /// used for decompression, decryption, etc.
/// The function receives a pointer to the received data, /// The function receives a pointer to the received data,
/// and must fill the packet with the transformed bytes. /// and must fill the packet with the transformed bytes.
/// The default implementation fills the packet directly /// The default implementation fills the packet directly
@ -300,12 +300,12 @@ private:
/// (sf::TcpSocket, sf::UdpSocket). /// (sf::TcpSocket, sf::UdpSocket).
/// ///
/// Packets solve 2 fundamental problems that arise when /// Packets solve 2 fundamental problems that arise when
/// transfering data over the network: /// transferring data over the network:
/// \li data is interpreted correctly according to the endianness /// \li data is interpreted correctly according to the endianness
/// \li the bounds of the packet are preserved (one send == one receive) /// \li the bounds of the packet are preserved (one send == one receive)
/// ///
/// The sf::Packet class provides both input and output modes. /// The sf::Packet class provides both input and output modes.
/// It is designed to follow the behaviour of standard C++ streams, /// It is designed to follow the behavior of standard C++ streams,
/// using operators >> and << to extract and insert data. /// using operators >> and << to extract and insert data.
/// ///
/// It is recommended to use only fixed-size types (like sf::Int32, etc.), /// It is recommended to use only fixed-size types (like sf::Int32, etc.),

View File

@ -188,7 +188,7 @@ private:
/// (socket classes are not copyable anyway), it simply keeps /// (socket classes are not copyable anyway), it simply keeps
/// a reference to the original sockets that you pass to the /// a reference to the original sockets that you pass to the
/// "add" function. Therefore, you can't use the selector as a /// "add" function. Therefore, you can't use the selector as a
/// socket container, you must store them oustide and make sure /// socket container, you must store them outside and make sure
/// that they are alive as long as they are used in the selector. /// that they are alive as long as they are used in the selector.
/// ///
/// Using a selector is simple: /// Using a selector is simple:

View File

@ -244,7 +244,7 @@ private:
/// class to get more details about how they work. /// class to get more details about how they work.
/// ///
/// The socket is automatically disconnected when it is destroyed, /// The socket is automatically disconnected when it is destroyed,
/// but if you want to explicitely close the connection while /// but if you want to explicitly close the connection while
/// the socket instance is still alive, you can call disconnect. /// the socket instance is still alive, you can call disconnect.
/// ///
/// Usage example: /// Usage example:

View File

@ -235,7 +235,7 @@ private:
/// ///
/// If the socket is bound to a port, it is automatically /// If the socket is bound to a port, it is automatically
/// unbound from it when the socket is destroyed. However, /// unbound from it when the socket is destroyed. However,
/// you can unbind the socket explicitely with the Unbind /// you can unbind the socket explicitly with the Unbind
/// function if necessary, to stop receiving messages or /// function if necessary, to stop receiving messages or
/// make the port available for other sockets. /// make the port available for other sockets.
/// ///

View File

@ -50,7 +50,7 @@
/// \defgroup system System module /// \defgroup system System module
/// ///
/// Base module of SFML, defining various utilities. It provides /// Base module of SFML, defining various utilities. It provides
/// vector classes, unicode strings and conversion functions, /// vector classes, Unicode strings and conversion functions,
/// threads and mutexes, timing classes. /// threads and mutexes, timing classes.
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////

View File

@ -107,7 +107,7 @@ private:
/// } // mutex is unlocked /// } // mutex is unlocked
/// \endcode /// \endcode
/// ///
/// Because the mutex is not explicitely unlocked in the code, /// Because the mutex is not explicitly unlocked in the code,
/// it may remain locked longer than needed. If the region /// it may remain locked longer than needed. If the region
/// of the code that needs to be protected by the mutex is /// of the code that needs to be protected by the mutex is
/// not the entire function, a good practice is to create a /// not the entire function, a good practice is to create a

View File

@ -47,7 +47,7 @@ protected:
/// ///
/// Because this class has a copy constructor, the compiler /// Because this class has a copy constructor, the compiler
/// will not automatically generate the default constructor. /// will not automatically generate the default constructor.
/// That's why we must define it explicitely. /// That's why we must define it explicitly.
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
NonCopyable() {} NonCopyable() {}
@ -89,7 +89,7 @@ private:
/// \class sf::NonCopyable /// \class sf::NonCopyable
/// \ingroup system /// \ingroup system
/// ///
/// This class makes its instances non-copyable, by explicitely /// This class makes its instances non-copyable, by explicitly
/// disabling its copy constructor and its assignment operator. /// disabling its copy constructor and its assignment operator.
/// ///
/// To create a non-copyable class, simply inherit from /// To create a non-copyable class, simply inherit from

View File

@ -49,7 +49,7 @@ public:
// Types // Types
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
typedef std::basic_string<Uint32>::iterator Iterator; ///< Iterator type typedef std::basic_string<Uint32>::iterator Iterator; ///< Iterator type
typedef std::basic_string<Uint32>::const_iterator ConstIterator; ///< Constant iterator type typedef std::basic_string<Uint32>::const_iterator ConstIterator; ///< Read-only iterator type
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
// Static member data // Static member data
@ -235,7 +235,7 @@ public:
operator std::wstring() const; operator std::wstring() const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Convert the unicode string to an ANSI string /// \brief Convert the Unicode string to an ANSI string
/// ///
/// The UTF-32 string is converted to an ANSI string in /// The UTF-32 string is converted to an ANSI string in
/// the encoding defined by \a locale. /// the encoding defined by \a locale.
@ -252,7 +252,7 @@ public:
std::string toAnsiString(const std::locale& locale = std::locale()) const; std::string toAnsiString(const std::locale& locale = std::locale()) const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Convert the unicode string to a wide string /// \brief Convert the Unicode string to a wide string
/// ///
/// Characters that do not fit in the target encoding are /// Characters that do not fit in the target encoding are
/// discarded from the returned string. /// discarded from the returned string.
@ -265,7 +265,7 @@ public:
std::wstring toWideString() const; std::wstring toWideString() const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Convert the unicode string to a UTF-8 string /// \brief Convert the Unicode string to a UTF-8 string
/// ///
/// \return Converted UTF-8 string /// \return Converted UTF-8 string
/// ///
@ -275,7 +275,7 @@ public:
std::basic_string<Uint8> toUtf8() const; std::basic_string<Uint8> toUtf8() const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Convert the unicode string to a UTF-16 string /// \brief Convert the Unicode string to a UTF-16 string
/// ///
/// \return Converted UTF-16 string /// \return Converted UTF-16 string
/// ///
@ -285,7 +285,7 @@ public:
std::basic_string<Uint16> toUtf16() const; std::basic_string<Uint16> toUtf16() const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Convert the unicode string to a UTF-32 string /// \brief Convert the Unicode string to a UTF-32 string
/// ///
/// This function doesn't perform any conversion, since the /// This function doesn't perform any conversion, since the
/// string is already stored as UTF-32 internally. /// string is already stored as UTF-32 internally.
@ -321,7 +321,7 @@ public:
/// \brief Overload of [] operator to access a character by its position /// \brief Overload of [] operator to access a character by its position
/// ///
/// This function provides read-only access to characters. /// This function provides read-only access to characters.
/// Note: this function doesn't throw if \a index is out of range. /// Note: the behavior is undefined if \a index is out of range.
/// ///
/// \param index Index of the character to get /// \param index Index of the character to get
/// ///
@ -334,7 +334,7 @@ public:
/// \brief Overload of [] operator to access a character by its position /// \brief Overload of [] operator to access a character by its position
/// ///
/// This function provides read and write access to characters. /// This function provides read and write access to characters.
/// Note: this function doesn't throw if \a index is out of range. /// Note: the behavior is undefined if \a index is out of range.
/// ///
/// \param index Index of the character to get /// \param index Index of the character to get
/// ///
@ -418,7 +418,7 @@ public:
/// and spans \a length characters with the string \a replaceWith. /// and spans \a length characters with the string \a replaceWith.
/// ///
/// \param position Index of the first character to be replaced /// \param position Index of the first character to be replaced
/// \param length Number of characters to replace. You can pass InvalidPos to /// \param length Number of characters to replace. You can pass InvalidPos to
/// replace all characters until the end of the string. /// replace all characters until the end of the string.
/// \param replaceWith String that replaces the given substring. /// \param replaceWith String that replaces the given substring.
/// ///
@ -428,7 +428,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Replace all occurrences of a substring with a replacement string /// \brief Replace all occurrences of a substring with a replacement string
/// ///
/// This function replaces all occurences of \a searchFor in this string /// This function replaces all occurrences of \a searchFor in this string
/// with the string \a replaceWith. /// with the string \a replaceWith.
/// ///
/// \param searchFor The value being searched for /// \param searchFor The value being searched for
@ -440,13 +440,13 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Return a part of the string /// \brief Return a part of the string
/// ///
/// This function returns the substring that starts at index \a position /// This function returns the substring that starts at index \a position
/// and spans \a length characters. /// and spans \a length characters.
/// ///
/// \param position Index of the first character /// \param position Index of the first character
/// \param length Number of characters to include in the substring (if /// \param length Number of characters to include in the substring (if
/// the string is shorter, as many characters as possible /// the string is shorter, as many characters as possible
/// are included). \ref InvalidPos can be used to include all /// are included). \ref InvalidPos can be used to include all
/// characters until the end of the string. /// characters until the end of the string.
/// ///
/// \return String object containing a substring of this object /// \return String object containing a substring of this object
@ -557,7 +557,7 @@ SFML_SYSTEM_API bool operator !=(const String& left, const String& right);
/// \param left Left operand (a string) /// \param left Left operand (a string)
/// \param right Right operand (a string) /// \param right Right operand (a string)
/// ///
/// \return True if \a left is alphabetically less than \a right /// \return True if \a left is lexicographically before \a right
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
SFML_SYSTEM_API bool operator <(const String& left, const String& right); SFML_SYSTEM_API bool operator <(const String& left, const String& right);
@ -569,7 +569,7 @@ SFML_SYSTEM_API bool operator <(const String& left, const String& right);
/// \param left Left operand (a string) /// \param left Left operand (a string)
/// \param right Right operand (a string) /// \param right Right operand (a string)
/// ///
/// \return True if \a left is alphabetically greater than \a right /// \return True if \a left is lexicographically after \a right
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
SFML_SYSTEM_API bool operator >(const String& left, const String& right); SFML_SYSTEM_API bool operator >(const String& left, const String& right);
@ -581,7 +581,7 @@ SFML_SYSTEM_API bool operator >(const String& left, const String& right);
/// \param left Left operand (a string) /// \param left Left operand (a string)
/// \param right Right operand (a string) /// \param right Right operand (a string)
/// ///
/// \return True if \a left is alphabetically less or equal than \a right /// \return True if \a left is lexicographically before or equivalent to \a right
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
SFML_SYSTEM_API bool operator <=(const String& left, const String& right); SFML_SYSTEM_API bool operator <=(const String& left, const String& right);
@ -593,7 +593,7 @@ SFML_SYSTEM_API bool operator <=(const String& left, const String& right);
/// \param left Left operand (a string) /// \param left Left operand (a string)
/// \param right Right operand (a string) /// \param right Right operand (a string)
/// ///
/// \return True if \a left is alphabetically greater or equal than \a right /// \return True if \a left is lexicographically after or equivalent to \a right
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
SFML_SYSTEM_API bool operator >=(const String& left, const String& right); SFML_SYSTEM_API bool operator >=(const String& left, const String& right);
@ -625,7 +625,7 @@ SFML_SYSTEM_API String operator +(const String& left, const String& right);
/// sf::String is a utility string class defined mainly for /// sf::String is a utility string class defined mainly for
/// convenience. It is a Unicode string (implemented using /// convenience. It is a Unicode string (implemented using
/// UTF-32), thus it can store any character in the world /// UTF-32), thus it can store any character in the world
/// (european, chinese, arabic, hebrew, etc.). /// (European, Chinese, Arabic, Hebrew, etc.).
/// ///
/// It automatically handles conversions from/to ANSI and /// It automatically handles conversions from/to ANSI and
/// wide strings, so that you can work with standard string /// wide strings, so that you can work with standard string

View File

@ -53,7 +53,7 @@ public:
/// \brief Construct the thread from a functor with no argument /// \brief Construct the thread from a functor with no argument
/// ///
/// This constructor works for function objects, as well /// This constructor works for function objects, as well
/// as free function. /// as free functions.
/// ///
/// Use this constructor for this kind of function: /// Use this constructor for this kind of function:
/// \code /// \code
@ -66,7 +66,7 @@ public:
/// void operator()(); /// void operator()();
/// }; /// };
/// \endcode /// \endcode
/// Note: this does *not* run the thread, use Launch(). /// Note: this does *not* run the thread, use launch().
/// ///
/// \param function Functor or free function to use as the entry point of the thread /// \param function Functor or free function to use as the entry point of the thread
/// ///
@ -78,7 +78,7 @@ public:
/// \brief Construct the thread from a functor with an argument /// \brief Construct the thread from a functor with an argument
/// ///
/// This constructor works for function objects, as well /// This constructor works for function objects, as well
/// as free function. /// as free functions.
/// It is a template, which means that the argument can /// It is a template, which means that the argument can
/// have any type (int, std::string, void*, Toto, ...). /// have any type (int, std::string, void*, Toto, ...).
/// ///
@ -93,7 +93,7 @@ public:
/// void operator()(std::string arg); /// void operator()(std::string arg);
/// }; /// };
/// \endcode /// \endcode
/// Note: this does *not* run the thread, use Launch(). /// Note: this does *not* run the thread, use launch().
/// ///
/// \param function Functor or free function to use as the entry point of the thread /// \param function Functor or free function to use as the entry point of the thread
/// \param argument argument to forward to the function /// \param argument argument to forward to the function
@ -105,7 +105,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Construct the thread from a member function and an object /// \brief Construct the thread from a member function and an object
/// ///
/// This constructor is template, which means that you can /// This constructor is a template, which means that you can
/// use it with any class. /// use it with any class.
/// Use this constructor for this kind of function: /// Use this constructor for this kind of function:
/// \code /// \code
@ -116,7 +116,7 @@ public:
/// void function(); /// void function();
/// }; /// };
/// \endcode /// \endcode
/// Note: this does *not* run the thread, use Launch(). /// Note: this does *not* run the thread, use launch().
/// ///
/// \param function Entry point of the thread /// \param function Entry point of the thread
/// \param object Pointer to the object to use /// \param object Pointer to the object to use
@ -128,7 +128,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Destructor /// \brief Destructor
/// ///
/// This destructor calls Wait(), so that the internal thread /// This destructor calls wait(), so that the internal thread
/// cannot survive after its sf::Thread instance is destroyed. /// cannot survive after its sf::Thread instance is destroyed.
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////

View File

@ -51,7 +51,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Default constructor /// \brief Default constructor
/// ///
/// \param value Optional value to initalize the variable /// \param value Optional value to initialize the variable
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
ThreadLocal(void* value = NULL); ThreadLocal(void* value = NULL);

View File

@ -45,7 +45,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Default constructor /// \brief Default constructor
/// ///
/// \param value Optional value to initalize the variable /// \param value Optional value to initialize the variable
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
ThreadLocalPtr(T* value = NULL); ThreadLocalPtr(T* value = NULL);
@ -54,9 +54,9 @@ public:
/// \brief Overload of unary operator * /// \brief Overload of unary operator *
/// ///
/// Like raw pointers, applying the * operator returns a /// Like raw pointers, applying the * operator returns a
/// reference to the pointed object. /// reference to the pointed-to object.
/// ///
/// \return Reference to the pointed object /// \return Reference to the thread-local variable
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
T& operator *() const; T& operator *() const;
@ -64,16 +64,16 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Overload of operator -> /// \brief Overload of operator ->
/// ///
/// Like raw pointers, applying the -> operator returns the /// Similarly to raw pointers, applying the -> operator
/// pointed object. /// returns the pointed-to object.
/// ///
/// \return Pointed object /// \return Pointer to the thread-local variable
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
T* operator ->() const; T* operator ->() const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Cast operator to implicitely convert the /// \brief Conversion operator to implicitly convert the
/// pointer to its raw pointer type (T*) /// pointer to its raw pointer type (T*)
/// ///
/// \return Pointer to the actual object /// \return Pointer to the actual object
@ -117,7 +117,7 @@ public:
/// sf::ThreadLocalPtr is a type-safe wrapper for storing /// sf::ThreadLocalPtr is a type-safe wrapper for storing
/// pointers to thread-local variables. A thread-local /// pointers to thread-local variables. A thread-local
/// variable holds a different value for each different /// variable holds a different value for each different
/// thread, unlike normal variable that are shared. /// thread, unlike normal variables that are shared.
/// ///
/// Its usage is completely transparent, so that it is similar /// Its usage is completely transparent, so that it is similar
/// to manipulating the raw pointer directly (like any smart pointer). /// to manipulating the raw pointer directly (like any smart pointer).

View File

@ -339,7 +339,7 @@ Out Utf<16>::encode(Uint32 input, Out output, Uint16 replacement)
} }
else if (input > 0x0010FFFF) else if (input > 0x0010FFFF)
{ {
// Invalid character (greater than the maximum unicode value) // Invalid character (greater than the maximum Unicode value)
if (replacement) if (replacement)
*output++ = replacement; *output++ = replacement;
} }
@ -638,7 +638,7 @@ Out Utf<32>::toUtf32(In begin, In end, Out output)
template <typename In> template <typename In>
Uint32 Utf<32>::decodeAnsi(In input, const std::locale& locale) Uint32 Utf<32>::decodeAnsi(In input, const std::locale& locale)
{ {
// On Windows, gcc's standard library (glibc++) has almost // On Windows, GCC's standard library (glibc++) has almost
// no support for Unicode stuff. As a consequence, in this // no support for Unicode stuff. As a consequence, in this
// context we can only use the default locale and ignore // context we can only use the default locale and ignore
// the one passed as parameter. // the one passed as parameter.

View File

@ -280,7 +280,7 @@ typedef Vector2<float> Vector2f;
/// \li sf::Vector2<unsigned int> is sf::Vector2u /// \li sf::Vector2<unsigned int> is sf::Vector2u
/// ///
/// The sf::Vector2 class has a small and simple interface, its x and y members /// The sf::Vector2 class has a small and simple interface, its x and y members
/// can be accessed directly (there's no accessor like setX(), getX()) and it /// can be accessed directly (there are no accessors like setX(), getX()) and it
/// contains no mathematical function like dot product, cross product, length, etc. /// contains no mathematical function like dot product, cross product, length, etc.
/// ///
/// Usage example: /// Usage example:

View File

@ -280,7 +280,7 @@ typedef Vector3<float> Vector3f;
/// \li sf::Vector3<int> is sf::Vector3i /// \li sf::Vector3<int> is sf::Vector3i
/// ///
/// The sf::Vector3 class has a small and simple interface, its x and y members /// The sf::Vector3 class has a small and simple interface, its x and y members
/// can be accessed directly (there's no accessor like setX(), getX()) and it /// can be accessed directly (there are no accessors like setX(), getX()) and it
/// contains no mathematical function like dot product, cross product, length, etc. /// contains no mathematical function like dot product, cross product, length, etc.
/// ///
/// Usage example: /// Usage example:

View File

@ -66,7 +66,7 @@ public:
~Context(); ~Context();
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Activate or deactivate explicitely the context /// \brief Activate or deactivate explicitly the context
/// ///
/// \param active True to activate, false to deactivate /// \param active True to activate, false to deactivate
/// ///

View File

@ -74,7 +74,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
struct TextEvent struct TextEvent
{ {
Uint32 unicode; ///< UTF-32 unicode value of the character Uint32 unicode; ///< UTF-32 Unicode value of the character
}; };
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////

View File

@ -157,9 +157,9 @@ public:
/// \brief Update the states of all joysticks /// \brief Update the states of all joysticks
/// ///
/// This function is used internally by SFML, so you normally /// This function is used internally by SFML, so you normally
/// don't have to call it explicitely. However, you may need to /// don't have to call it explicitly. However, you may need to
/// call it if you have no window yet (or no window at all): /// call it if you have no window yet (or no window at all):
/// in this case the joysticks states are not updated automatically. /// in this case the joystick states are not updated automatically.
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
static void update(); static void update();
@ -202,7 +202,7 @@ public:
/// joysticks. When you have a window with event handling, this is done /// joysticks. When you have a window with event handling, this is done
/// automatically, you don't need to call anything. But if you have no /// automatically, you don't need to call anything. But if you have no
/// window, or if you want to check joysticks state before creating one, /// window, or if you want to check joysticks state before creating one,
/// you must call sf::Joystick::update explicitely. /// you must call sf::Joystick::update explicitly.
/// ///
/// Usage example: /// Usage example:
/// \code /// \code

View File

@ -107,7 +107,7 @@ public:
/// ///
/// sf::Sensor provides an interface to the state of the /// sf::Sensor provides an interface to the state of the
/// various sensors that a device provides. It only contains static /// various sensors that a device provides. It only contains static
/// functions, so it's not meant to be instanciated. /// functions, so it's not meant to be instantiated.
/// ///
/// This class allows users to query the sensors values at any /// This class allows users to query the sensors values at any
/// time and directly, without having to deal with a window and /// time and directly, without having to deal with a window and

View File

@ -94,7 +94,7 @@ public:
/// ///
/// sf::Touch provides an interface to the state of the /// sf::Touch provides an interface to the state of the
/// touches. It only contains static functions, so it's not /// touches. It only contains static functions, so it's not
/// meant to be instanciated. /// meant to be instantiated.
/// ///
/// This class allows users to query the touches state at any /// This class allows users to query the touches state at any
/// time and directly, without having to deal with a window and /// time and directly, without having to deal with a window and

View File

@ -203,7 +203,7 @@ SFML_WINDOW_API bool operator >=(const VideoMode& left, const VideoMode& right);
/// A custom video mode can also be checked directly for /// A custom video mode can also be checked directly for
/// fullscreen compatibility with its isValid() function. /// fullscreen compatibility with its isValid() function.
/// ///
/// Additionnally, sf::VideoMode provides a static function /// Additionally, sf::VideoMode provides a static function
/// to get the mode currently used by the desktop: getDesktopMode(). /// to get the mode currently used by the desktop: getDesktopMode().
/// This allows to build windows with the same size or pixel /// This allows to build windows with the same size or pixel
/// depth as the current resolution. /// depth as the current resolution.

View File

@ -72,7 +72,7 @@ public:
/// ///
/// This constructor creates the window with the size and pixel /// This constructor creates the window with the size and pixel
/// depth defined in \a mode. An optional style can be passed to /// depth defined in \a mode. An optional style can be passed to
/// customize the look and behaviour of the window (borders, /// customize the look and behavior of the window (borders,
/// title bar, resizable, closable, ...). If \a style contains /// title bar, resizable, closable, ...). If \a style contains
/// Style::Fullscreen, then \a mode must be a valid video mode. /// Style::Fullscreen, then \a mode must be a valid video mode.
/// ///
@ -217,7 +217,7 @@ public:
/// ///
/// This function is blocking: if there's no pending event then /// This function is blocking: if there's no pending event then
/// it will wait until an event is received. /// it will wait until an event is received.
/// After this function returns (and no error occured), /// After this function returns (and no error occurred),
/// the \a event object is always valid and filled properly. /// the \a event object is always valid and filled properly.
/// This function is typically used when you have a thread that /// This function is typically used when you have a thread that
/// is dedicated to events handling: you want to make this thread /// is dedicated to events handling: you want to make this thread
@ -232,7 +232,7 @@ public:
/// ///
/// \param event Event to be returned /// \param event Event to be returned
/// ///
/// \return False if any error occured /// \return False if any error occurred
/// ///
/// \see pollEvent /// \see pollEvent
/// ///

View File

@ -315,7 +315,7 @@ void SoundStream::streamData()
} }
} }
// Get the number of buffers that have been processed (ie. ready for reuse) // Get the number of buffers that have been processed (i.e. ready for reuse)
ALint nbProcessed = 0; ALint nbProcessed = 0;
alCheck(alGetSourcei(m_source, AL_BUFFERS_PROCESSED, &nbProcessed)); alCheck(alGetSourcei(m_source, AL_BUFFERS_PROCESSED, &nbProcessed));
@ -381,7 +381,7 @@ void SoundStream::streamData()
// Stop the playback // Stop the playback
alCheck(alSourceStop(m_source)); alCheck(alSourceStop(m_source));
// Unqueue any buffer left in the queue // Dequeue any buffer left in the queue
clearQueue(); clearQueue();
// Delete the buffers // Delete the buffers
@ -460,7 +460,7 @@ void SoundStream::clearQueue()
ALint nbQueued; ALint nbQueued;
alCheck(alGetSourcei(m_source, AL_BUFFERS_QUEUED, &nbQueued)); alCheck(alGetSourcei(m_source, AL_BUFFERS_QUEUED, &nbQueued));
// Unqueue them all // Dequeue them all
ALuint buffer; ALuint buffer;
for (ALint i = 0; i < nbQueued; ++i) for (ALint i = 0; i < nbQueued; ++i)
alCheck(alSourceUnqueueBuffers(m_source, 1, &buffer)); alCheck(alSourceUnqueueBuffers(m_source, 1, &buffer));

View File

@ -197,7 +197,7 @@ bool Font::loadFromMemory(const void* data, std::size_t sizeInBytes)
return false; return false;
} }
// Select the unicode character map // Select the Unicode character map
if (FT_Select_Charmap(face, FT_ENCODING_UNICODE) != 0) if (FT_Select_Charmap(face, FT_ENCODING_UNICODE) != 0)
{ {
err() << "Failed to load font from memory (failed to set the Unicode character set)" << std::endl; err() << "Failed to load font from memory (failed to set the Unicode character set)" << std::endl;
@ -261,7 +261,7 @@ bool Font::loadFromStream(InputStream& stream)
return false; return false;
} }
// Select the unicode character map // Select the Unicode character map
if (FT_Select_Charmap(face, FT_ENCODING_UNICODE) != 0) if (FT_Select_Charmap(face, FT_ENCODING_UNICODE) != 0)
{ {
err() << "Failed to load font from stream (failed to set the Unicode character set)" << std::endl; err() << "Failed to load font from stream (failed to set the Unicode character set)" << std::endl;
@ -520,7 +520,7 @@ Glyph Font::loadGlyph(Uint32 codePoint, unsigned int characterSize, bool bold) c
if ((width > 0) && (height > 0)) if ((width > 0) && (height > 0))
{ {
// Leave a small padding around characters, so that filtering doesn't // Leave a small padding around characters, so that filtering doesn't
// pollute them with pixels from neighbours // pollute them with pixels from neighbors
const unsigned int padding = 1; const unsigned int padding = 1;
// Get the glyphs page corresponding to the character size // Get the glyphs page corresponding to the character size
@ -529,7 +529,7 @@ Glyph Font::loadGlyph(Uint32 codePoint, unsigned int characterSize, bool bold) c
// Find a good position for the new glyph into the texture // Find a good position for the new glyph into the texture
glyph.textureRect = findGlyphRect(page, width + 2 * padding, height + 2 * padding); glyph.textureRect = findGlyphRect(page, width + 2 * padding, height + 2 * padding);
// Make sure the texture data is positioned in the centre // Make sure the texture data is positioned in the center
// of the allocated texture rectangle // of the allocated texture rectangle
glyph.textureRect.left += padding; glyph.textureRect.left += padding;
glyph.textureRect.top += padding; glyph.textureRect.top += padding;

View File

@ -286,7 +286,7 @@ bool ImageLoader::writeJpg(const std::string& filename, const std::vector<Uint8>
jpeg_set_defaults(&compressInfos); jpeg_set_defaults(&compressInfos);
jpeg_set_quality(&compressInfos, 90, TRUE); jpeg_set_quality(&compressInfos, 90, TRUE);
// Get rid of the aplha channel // Get rid of the alpha channel
std::vector<Uint8> buffer(width * height * 3); std::vector<Uint8> buffer(width * height * 3);
for (std::size_t i = 0; i < width * height; ++i) for (std::size_t i = 0; i < width * height; ++i)
{ {

View File

@ -39,7 +39,7 @@ namespace priv
{ {
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Default specialization of RenderTextureImpl, /// \brief Default specialization of RenderTextureImpl,
/// using a in-memory context /// using an in-memory context
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
class RenderTextureImplDefault : public RenderTextureImpl, GlResource class RenderTextureImplDefault : public RenderTextureImpl, GlResource

View File

@ -632,7 +632,7 @@ int Shader::getParamLocation(const std::string& name)
#else // SFML_OPENGL_ES #else // SFML_OPENGL_ES
// OpenGL ES 1 does't support GLSL shaders at all, we have to provide an empty implementation // OpenGL ES 1 doesn't support GLSL shaders at all, we have to provide an empty implementation
namespace sf namespace sf
{ {

View File

@ -64,7 +64,7 @@ ActivityStates* retrieveStates(ANativeActivity* activity)
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
static void initializeMain(ActivityStates* states) static void initializeMain(ActivityStates* states)
{ {
// Protect from concurent access // Protect from concurrent access
Lock lock(states->mutex); Lock lock(states->mutex);
// Prepare and share the looper to be read later // Prepare and share the looper to be read later
@ -80,7 +80,7 @@ static void initializeMain(ActivityStates* states)
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
static void terminateMain(ActivityStates* states) static void terminateMain(ActivityStates* states)
{ {
// Protect from concurent access // Protect from concurrent access
Lock lock(states->mutex); Lock lock(states->mutex);
// The main thread has finished, we must explicitly ask the activity to finish // The main thread has finished, we must explicitly ask the activity to finish
@ -154,7 +154,7 @@ void goToFullscreenMode(ANativeActivity* activity)
void getScreenSizeInPixels(ANativeActivity* activity, int* width, int* height) void getScreenSizeInPixels(ANativeActivity* activity, int* width, int* height)
{ {
// Perform the following java code: // Perform the following Java code:
// //
// DisplayMetrics dm = new DisplayMetrics(); // DisplayMetrics dm = new DisplayMetrics();
// getWindowManager().getDefaultDisplay().getMetrics(dm); // getWindowManager().getDefaultDisplay().getMetrics(dm);

View File

@ -41,7 +41,7 @@ std::string getLibraryName(JNIEnv* lJNIEnv, jobject& objectActivityInfo)
{ {
// This function reads the value of meta-data "sfml.app.lib_name" // This function reads the value of meta-data "sfml.app.lib_name"
// found in the Android Manifest file and returns it. It performs the // found in the Android Manifest file and returns it. It performs the
// following java code using the JNI interface: // following Java code using the JNI interface:
// //
// ai.metaData.getString("sfml.app.lib_name"); // ai.metaData.getString("sfml.app.lib_name");

View File

@ -37,7 +37,7 @@ namespace
{ {
if (address == "255.255.255.255") if (address == "255.255.255.255")
{ {
// The broadcast address needs to be handled explicitely, // The broadcast address needs to be handled explicitly,
// because it is also the value returned by inet_addr on error // because it is also the value returned by inet_addr on error
return INADDR_BROADCAST; return INADDR_BROADCAST;
} }
@ -84,7 +84,7 @@ m_address(0)
{ {
// We're using 0 (INADDR_ANY) instead of INADDR_NONE to represent the invalid address, // We're using 0 (INADDR_ANY) instead of INADDR_NONE to represent the invalid address,
// because the latter is also the broadcast address (255.255.255.255); it's ok because // because the latter is also the broadcast address (255.255.255.255); it's ok because
// SFML doesn't publicly use INADDR_ANY (it is always used implicitely) // SFML doesn't publicly use INADDR_ANY (it is always used implicitly)
} }

View File

@ -101,7 +101,7 @@ void Socket::create(SocketHandle handle)
if (m_type == Tcp) if (m_type == Tcp)
{ {
// Disable the Nagle algorithm (ie. removes buffering of TCP packets) // Disable the Nagle algorithm (i.e. removes buffering of TCP packets)
int yes = 1; int yes = 1;
if (setsockopt(m_socket, IPPROTO_TCP, TCP_NODELAY, reinterpret_cast<char*>(&yes), sizeof(yes)) == -1) if (setsockopt(m_socket, IPPROTO_TCP, TCP_NODELAY, reinterpret_cast<char*>(&yes), sizeof(yes)) == -1)
{ {

View File

@ -157,7 +157,7 @@ Socket::Status TcpSocket::connect(const IpAddress& remoteAddress, unsigned short
// Get the error status // Get the error status
Status status = priv::SocketImpl::getErrorStatus(); Status status = priv::SocketImpl::getErrorStatus();
// If we were in non-blocking mode, return immediatly // If we were in non-blocking mode, return immediately
if (!blocking) if (!blocking)
return status; return status;

View File

@ -33,7 +33,7 @@
namespace namespace
{ {
// This class will be used as the default streambuf of sf::Err, // This class will be used as the default streambuf of sf::Err,
// it outputs to stderr by default (to keep the default behaviour) // it outputs to stderr by default (to keep the default behavior)
class DefaultErrStreamBuf : public std::streambuf class DefaultErrStreamBuf : public std::streambuf
{ {
public: public:

View File

@ -295,7 +295,7 @@ void String::replace(const String& searchFor, const String& replaceWith)
std::size_t len = searchFor.getSize(); std::size_t len = searchFor.getSize();
std::size_t pos = find(searchFor); std::size_t pos = find(searchFor);
// Replace each occurence of search // Replace each occurrence of search
while (pos != InvalidPos) while (pos != InvalidPos)
{ {
replace(pos, len, replaceWith); replace(pos, len, replaceWith);

View File

@ -37,7 +37,7 @@ namespace sf
namespace priv namespace priv
{ {
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Unix implementaton of sf::Clock /// \brief Unix implementation of sf::Clock
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
class ClockImpl class ClockImpl

View File

@ -35,7 +35,7 @@ namespace priv
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
MutexImpl::MutexImpl() MutexImpl::MutexImpl()
{ {
// Make it recursive to follow the expected behaviour // Make it recursive to follow the expected behavior
pthread_mutexattr_t attributes; pthread_mutexattr_t attributes;
pthread_mutexattr_init(&attributes); pthread_mutexattr_init(&attributes);
pthread_mutexattr_settype(&attributes, PTHREAD_MUTEX_RECURSIVE); pthread_mutexattr_settype(&attributes, PTHREAD_MUTEX_RECURSIVE);

View File

@ -79,7 +79,7 @@ void* ThreadImpl::entryPoint(void* userData)
Thread* owner = static_cast<Thread*>(userData); Thread* owner = static_cast<Thread*>(userData);
#ifndef SFML_SYSTEM_ANDROID #ifndef SFML_SYSTEM_ANDROID
// Tell the thread to handle cancel requests immediatly // Tell the thread to handle cancel requests immediately
pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL); pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL);
#endif #endif

View File

@ -37,7 +37,7 @@ namespace sf
namespace priv namespace priv
{ {
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Windows implementaton of sf::Clock /// \brief Windows implementation of sf::Clock
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
class ClockImpl class ClockImpl

View File

@ -139,7 +139,7 @@ ASensor const* SensorImpl::getDefaultSensor(Sensor::Type sensor)
int type = types[sensor]; int type = types[sensor];
// Retrive the default sensor matching this type // Retrieve the default sensor matching this type
return ASensorManager_getDefaultSensor(sensorManager, type); return ASensorManager_getDefaultSensor(sensorManager, type);
} }

View File

@ -300,7 +300,7 @@ int WindowImplAndroid::processEvent(int fd, int events, void* data)
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void WindowImplAndroid::processScrollEvent(AInputEvent* _event, ActivityStates* states) void WindowImplAndroid::processScrollEvent(AInputEvent* _event, ActivityStates* states)
{ {
// Prepare the java virtual machine // Prepare the Java virtual machine
jint lResult; jint lResult;
jint lFlags = 0; jint lFlags = 0;
@ -315,9 +315,9 @@ void WindowImplAndroid::processScrollEvent(AInputEvent* _event, ActivityStates*
lResult=lJavaVM->AttachCurrentThread(&lJNIEnv, &lJavaVMAttachArgs); lResult=lJavaVM->AttachCurrentThread(&lJNIEnv, &lJavaVMAttachArgs);
if (lResult == JNI_ERR) if (lResult == JNI_ERR)
err() << "Failed to initialize JNI, couldn't get the unicode value" << std::endl; err() << "Failed to initialize JNI, couldn't get the Unicode value" << std::endl;
// Retrieve everything we need to create this MotionEvent in java // Retrieve everything we need to create this MotionEvent in Java
jlong downTime = AMotionEvent_getDownTime(_event); jlong downTime = AMotionEvent_getDownTime(_event);
jlong eventTime = AMotionEvent_getEventTime(_event); jlong eventTime = AMotionEvent_getEventTime(_event);
jint action = AMotionEvent_getAction(_event); jint action = AMotionEvent_getAction(_event);
@ -331,7 +331,7 @@ void WindowImplAndroid::processScrollEvent(AInputEvent* _event, ActivityStates*
jint deviceId = AInputEvent_getDeviceId(_event); jint deviceId = AInputEvent_getDeviceId(_event);
jint edgeFlags = AMotionEvent_getEdgeFlags(_event); jint edgeFlags = AMotionEvent_getEdgeFlags(_event);
// Create the MotionEvent object in java trough its static constructor obtain() // Create the MotionEvent object in Java trough its static constructor obtain()
jclass ClassMotionEvent = lJNIEnv->FindClass("android/view/MotionEvent"); jclass ClassMotionEvent = lJNIEnv->FindClass("android/view/MotionEvent");
jmethodID StaticMethodObtain = lJNIEnv->GetStaticMethodID(ClassMotionEvent, "obtain", "(JJIFFFFIFFII)Landroid/view/MotionEvent;"); jmethodID StaticMethodObtain = lJNIEnv->GetStaticMethodID(ClassMotionEvent, "obtain", "(JJIFFFFIFFII)Landroid/view/MotionEvent;");
jobject ObjectMotionEvent = lJNIEnv->CallStaticObjectMethod(ClassMotionEvent, StaticMethodObtain, downTime, eventTime, action, x, y, pressure, size, metaState, xPrecision, yPrecision, deviceId, edgeFlags); jobject ObjectMotionEvent = lJNIEnv->CallStaticObjectMethod(ClassMotionEvent, StaticMethodObtain, downTime, eventTime, action, x, y, pressure, size, metaState, xPrecision, yPrecision, deviceId, edgeFlags);
@ -349,7 +349,7 @@ void WindowImplAndroid::processScrollEvent(AInputEvent* _event, ActivityStates*
forwardEvent(event); forwardEvent(event);
// Dettach this thread from the JVM // Detach this thread from the JVM
lJavaVM->DetachCurrentThread(); lJavaVM->DetachCurrentThread();
} }
@ -670,7 +670,7 @@ int WindowImplAndroid::getUnicode(AInputEvent* event)
lResult=lJavaVM->AttachCurrentThread(&lJNIEnv, &lJavaVMAttachArgs); lResult=lJavaVM->AttachCurrentThread(&lJNIEnv, &lJavaVMAttachArgs);
if (lResult == JNI_ERR) if (lResult == JNI_ERR)
err() << "Failed to initialize JNI, couldn't get the unicode value" << std::endl; err() << "Failed to initialize JNI, couldn't get the Unicode value" << std::endl;
// Retrieve key data from the input event // Retrieve key data from the input event
jlong downTime = AKeyEvent_getDownTime(event); jlong downTime = AKeyEvent_getDownTime(event);
@ -689,11 +689,11 @@ int WindowImplAndroid::getUnicode(AInputEvent* event)
jmethodID KeyEventConstructor = lJNIEnv->GetMethodID(ClassKeyEvent, "<init>", "(JJIIIIIIII)V"); jmethodID KeyEventConstructor = lJNIEnv->GetMethodID(ClassKeyEvent, "<init>", "(JJIIIIIIII)V");
jobject ObjectKeyEvent = lJNIEnv->NewObject(ClassKeyEvent, KeyEventConstructor, downTime, eventTime, action, code, repeat, metaState, deviceId, scancode, flags, source); jobject ObjectKeyEvent = lJNIEnv->NewObject(ClassKeyEvent, KeyEventConstructor, downTime, eventTime, action, code, repeat, metaState, deviceId, scancode, flags, source);
// Call its getUnicodeChar() method to get the unicode value // Call its getUnicodeChar() method to get the Unicode value
jmethodID MethodGetUnicode = lJNIEnv->GetMethodID(ClassKeyEvent, "getUnicodeChar", "(I)I"); jmethodID MethodGetUnicode = lJNIEnv->GetMethodID(ClassKeyEvent, "getUnicodeChar", "(I)I");
int unicode = lJNIEnv->CallIntMethod(ObjectKeyEvent, MethodGetUnicode, metaState); int unicode = lJNIEnv->CallIntMethod(ObjectKeyEvent, MethodGetUnicode, metaState);
// Dettach this thread from the JVM // Detach this thread from the JVM
lJavaVM->DetachCurrentThread(); lJavaVM->DetachCurrentThread();
return unicode; return unicode;

View File

@ -204,17 +204,17 @@ private:
/// ///
/// \param symbol Android key to convert /// \param symbol Android key to convert
/// ///
/// \return Corrsponding SFML key code /// \return Corresponding SFML key code
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
static Keyboard::Key androidKeyToSF(int32_t key); static Keyboard::Key androidKeyToSF(int32_t key);
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Get unicode decoded from the input event /// \brief Get Unicode decoded from the input event
/// ///
/// \param Event Input event /// \param Event Input event
/// ///
/// \return The unicode value /// \return The Unicode value
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
static int getUnicode(AInputEvent* event); static int getUnicode(AInputEvent* event);

View File

@ -144,7 +144,7 @@ void eglCheckError(const char* file, unsigned int line)
case EGL_CONTEXT_LOST: case EGL_CONTEXT_LOST:
{ {
error = "EGL_CONTEXT_LOST"; error = "EGL_CONTEXT_LOST";
description = "a power management event has occured. The application must destroy all contexts and reinitialise client API state and objects to continue rendering"; description = "a power management event has occurred. The application must destroy all contexts and reinitialize client API state and objects to continue rendering";
break; break;
} }
} }

View File

@ -80,7 +80,7 @@ m_context (EGL_NO_CONTEXT),
m_surface (EGL_NO_SURFACE), m_surface (EGL_NO_SURFACE),
m_config (NULL) m_config (NULL)
{ {
// Get the intialized EGL display // Get the initialized EGL display
m_display = getInitializedDisplay(); m_display = getInitializedDisplay();
// Get the best EGL config matching the default video settings // Get the best EGL config matching the default video settings
@ -118,7 +118,7 @@ m_config (NULL)
#endif #endif
// Get the intialized EGL display // Get the initialized EGL display
m_display = getInitializedDisplay(); m_display = getInitializedDisplay();
// Get the best EGL config matching the requested video settings // Get the best EGL config matching the requested video settings
@ -148,7 +148,7 @@ m_config (NULL)
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
EglContext::~EglContext() EglContext::~EglContext()
{ {
// Desactive the current context // Deactivate the current context
EGLContext currentContext = eglCheck(eglGetCurrentContext()); EGLContext currentContext = eglCheck(eglGetCurrentContext());
if (currentContext == m_context) if (currentContext == m_context)
@ -258,7 +258,7 @@ EGLConfig EglContext::getBestConfig(EGLDisplay display, unsigned int bitsPerPixe
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
XVisualInfo EglContext::selectBestVisual(::Display* XDisplay, unsigned int bitsPerPixel, const ContextSettings& settings) XVisualInfo EglContext::selectBestVisual(::Display* XDisplay, unsigned int bitsPerPixel, const ContextSettings& settings)
{ {
// Get the intialized EGL display // Get the initialized EGL display
EGLDisplay display = getInitializedDisplay(); EGLDisplay display = getInitializedDisplay();
// Get the best EGL config matching the default video settings // Get the best EGL config matching the default video settings

View File

@ -219,7 +219,7 @@ bool JoystickImpl::open(unsigned int index)
// And the id // And the id
m_id = hid_get_report_id(m_file); m_id = hid_get_report_id(m_file);
// Then allocate a buffer for data retrievement // Then allocate a buffer for data retrieval
m_length = hid_report_size(m_desc, hid_input, m_id); m_length = hid_report_size(m_desc, hid_input, m_id);
m_buffer.resize(m_length); m_buffer.resize(m_length);

View File

@ -201,7 +201,7 @@ protected:
/// lower the score is, the better the configuration is. /// lower the score is, the better the configuration is.
/// ///
/// \param bitsPerPixel Requested pixel depth (bits per pixel) /// \param bitsPerPixel Requested pixel depth (bits per pixel)
/// \param settings Requested additionnal settings /// \param settings Requested additional settings
/// \param colorBits Color bits of the configuration to evaluate /// \param colorBits Color bits of the configuration to evaluate
/// \param depthBits Depth bits of the configuration to evaluate /// \param depthBits Depth bits of the configuration to evaluate
/// \param stencilBits Stencil bits of the configuration to evaluate /// \param stencilBits Stencil bits of the configuration to evaluate

View File

@ -54,7 +54,7 @@ long HIDInputManager::getLocationID(IOHIDDeviceRef device)
{ {
long loc = 0; long loc = 0;
// Get a unique ID: its usb location ID // Get a unique ID: its USB location ID
CFTypeRef typeRef = IOHIDDeviceGetProperty(device, CFTypeRef typeRef = IOHIDDeviceGetProperty(device,
CFSTR(kIOHIDLocationIDKey)); CFSTR(kIOHIDLocationIDKey));
if (!typeRef || (CFGetTypeID(typeRef) != CFNumberGetTypeID())) if (!typeRef || (CFGetTypeID(typeRef) != CFNumberGetTypeID()))
@ -225,7 +225,7 @@ void HIDInputManager::loadKey(IOHIDElementRef key)
if (virtualCode == 0xff) if (virtualCode == 0xff)
return; // no corresponding virtual code -> skip return; // no corresponding virtual code -> skip
// Now translate the virtual code to unicode according to // Now translate the virtual code to Unicode according to
// the current keyboard layout // the current keyboard layout
UInt32 deadKeyState = 0; UInt32 deadKeyState = 0;
@ -286,7 +286,7 @@ void HIDInputManager::loadKey(IOHIDElementRef key)
// 0x4c | 0x77 | Select // 0x4c | 0x77 | Select
//if (code == Keyboard::Unknown) { // The key is unknown. //if (code == Keyboard::Unknown) { // The key is unknown.
// sf::err() << "This is an unknow key. Virtual key code is 0x" // sf::err() << "This is an unknown key. Virtual key code is 0x"
// << std::hex // << std::hex
// << (UInt32)virtualCode // << (UInt32)virtualCode
// << " and HID usage code is 0x" // << " and HID usage code is 0x"

View File

@ -126,7 +126,7 @@ private:
Joystick::Identification m_identification; ///< Joystick identification Joystick::Identification m_identification; ///< Joystick identification
static Location m_locationIDs[sf::Joystick::Count]; ///< Global Joystick register static Location m_locationIDs[sf::Joystick::Count]; ///< Global Joystick register
/// For a corresponding SFML index, m_locationIDs is either some usb /// For a corresponding SFML index, m_locationIDs is either some USB
/// location or 0 if there isn't currently a connected joystick device /// location or 0 if there isn't currently a connected joystick device
}; };

View File

@ -30,7 +30,7 @@
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Event processing & Menu bar initialisation /// \brief Event processing & Menu bar initialization
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
@interface SFApplication : NSApplication @interface SFApplication : NSApplication

View File

@ -665,7 +665,7 @@ BOOL isValidTextUnicode(NSEvent* event);
} }
// Handle text entred event: // Handle text entered event:
// Ignore event if we don't want repeated keystrokes // Ignore event if we don't want repeated keystrokes
if (m_useKeyRepeat || ![theEvent isARepeat]) if (m_useKeyRepeat || ![theEvent isARepeat])
{ {
@ -687,7 +687,7 @@ BOOL isValidTextUnicode(NSEvent* event);
// Backspace // Backspace
if (keycode == 0x33) if (keycode == 0x33)
{ {
// Send the correct unicode value (i.e. 8) instead of 127 (which is 'delete') // Send the correct Unicode value (i.e. 8) instead of 127 (which is 'delete')
m_requester->textEntered(8); m_requester->textEntered(8);
} }
@ -770,7 +770,7 @@ BOOL isValidTextUnicode(NSEvent* event);
//#ifdef SFML_DEBUG // Don't bother the final customers with annoying messages. //#ifdef SFML_DEBUG // Don't bother the final customers with annoying messages.
// if (key.code == sf::Keyboard::Unknown) { // The key is unknown. // if (key.code == sf::Keyboard::Unknown) { // The key is unknown.
// sf::err() << "This is an unknow key. Virtual key code is 0x" // sf::err() << "This is an unknown key. Virtual key code is 0x"
// << std::hex // << std::hex
// << [event keyCode] // << [event keyCode]
// << "." // << "."

View File

@ -386,7 +386,7 @@
//////////////////////////////////////////////////////// ////////////////////////////////////////////////////////
-(void)resizeTo:(unsigned int)width by:(unsigned int)height -(void)resizeTo:(unsigned int)width by:(unsigned int)height
{ {
// Before resizing, remove resizeable mask to be able to resize // Before resizing, remove resizable mask to be able to resize
// beyond the desktop boundaries. // beyond the desktop boundaries.
NSUInteger styleMask = [m_window styleMask]; NSUInteger styleMask = [m_window styleMask];

View File

@ -383,7 +383,7 @@ void WindowImplX11::setSize(const Vector2u& size)
void WindowImplX11::setTitle(const String& title) void WindowImplX11::setTitle(const String& title)
{ {
// Bare X11 has no Unicode window title support. // Bare X11 has no Unicode window title support.
// There is however an option to tell the window manager your unicode title via hints. // There is however an option to tell the window manager your Unicode title via hints.
// Convert to UTF-8 encoding. // Convert to UTF-8 encoding.
std::basic_string<Uint8> utf8Title; std::basic_string<Uint8> utf8Title;

View File

@ -220,7 +220,7 @@ private:
/// ///
/// \param symbol Key symbol to convert /// \param symbol Key symbol to convert
/// ///
/// \return Corrsponding SFML key code /// \return Corresponding SFML key code
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
static Keyboard::Key keysymToSF(KeySym symbol); static Keyboard::Key keysymToSF(KeySym symbol);
@ -232,11 +232,11 @@ private:
::Display* m_display; ///< Pointer to the display ::Display* m_display; ///< Pointer to the display
int m_screen; ///< Screen identifier int m_screen; ///< Screen identifier
XIM m_inputMethod; ///< Input method linked to the X display XIM m_inputMethod; ///< Input method linked to the X display
XIC m_inputContext; ///< Input context used to get unicode input in our window XIC m_inputContext; ///< Input context used to get Unicode input in our window
bool m_isExternal; ///< Tell whether the window has been created externally or by SFML bool m_isExternal; ///< Tell whether the window has been created externally or by SFML
Atom m_atomClose; ///< Atom used to identify the close event Atom m_atomClose; ///< Atom used to identify the close event
int m_oldVideoMode; ///< Video mode in use before we switch to fullscreen int m_oldVideoMode; ///< Video mode in use before we switch to fullscreen
Cursor m_hiddenCursor; ///< As X11 doesn't provide cursor hidding, we must create a transparent one Cursor m_hiddenCursor; ///< As X11 doesn't provide cursor hiding, we must create a transparent one
bool m_keyRepeat; ///< Is the KeyRepeat feature enabled? bool m_keyRepeat; ///< Is the KeyRepeat feature enabled?
Vector2i m_previousSize; ///< Previous size of the window, to find if a ConfigureNotify event is a resize event (could be a move event only) Vector2i m_previousSize; ///< Previous size of the window, to find if a ConfigureNotify event is a resize event (could be a move event only)
bool m_useSizeHints; ///< Is the size of the window fixed with size hints? bool m_useSizeHints; ///< Is the size of the window fixed with size hints?

View File

@ -177,7 +177,7 @@ void JoystickImpl::cleanup()
bool JoystickImpl::isConnected(unsigned int index) bool JoystickImpl::isConnected(unsigned int index)
{ {
// We check the connection state of joysticks only every N milliseconds, // We check the connection state of joysticks only every N milliseconds,
// because of a strange (buggy?) behaviour of joyGetPosEx when joysticks // because of a strange (buggy?) behavior of joyGetPosEx when joysticks
// are just plugged/unplugged -- it takes really long and kills the app performances // are just plugged/unplugged -- it takes really long and kills the app performances
ConnectionCache& cache = connectionCache[index]; ConnectionCache& cache = connectionCache[index];
if (cache.timer.getElapsedTime() > connectionRefreshDelay) if (cache.timer.getElapsedTime() > connectionRefreshDelay)

View File

@ -410,7 +410,7 @@ bool Window::filterEvent(const Event& event)
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void Window::initialize() void Window::initialize()
{ {
// Setup default behaviours (to get a consistent behaviour across different implementations) // Setup default behaviors (to get a consistent behavior across different implementations)
setVisible(true); setVisible(true);
setMouseCursorVisible(true); setMouseCursorVisible(true);
setVerticalSyncEnabled(false); setVerticalSyncEnabled(false);

View File

@ -88,7 +88,7 @@ public:
virtual ~WindowImpl(); virtual ~WindowImpl();
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Change the joystick threshold, ie. the value below which /// \brief Change the joystick threshold, i.e. the value below which
/// no move event will be generated /// no move event will be generated
/// ///
/// \param threshold New threshold, in range [0, 100] /// \param threshold New threshold, in range [0, 100]
@ -101,7 +101,7 @@ public:
/// ///
/// If there's no event available, this function calls the /// If there's no event available, this function calls the
/// window's internal event processing function. /// window's internal event processing function.
/// The \a block parameter controls the behaviour of the function /// The \a block parameter controls the behavior of the function
/// if no event is available: if it is true then the function /// if no event is available: if it is true then the function
/// doesn't return until a new event is triggered; otherwise it /// doesn't return until a new event is triggered; otherwise it
/// returns false to indicate that no event is available. /// returns false to indicate that no event is available.

View File

@ -59,7 +59,7 @@ public:
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
EaglContext(EaglContext* shared); EaglContext(EaglContext* shared);
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Create a new context attached to a window /// \brief Create a new context attached to a window
/// ///
@ -71,7 +71,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
EaglContext(EaglContext* shared, const ContextSettings& settings, EaglContext(EaglContext* shared, const ContextSettings& settings,
const WindowImpl* owner, unsigned int bitsPerPixel); const WindowImpl* owner, unsigned int bitsPerPixel);
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Create a new context that embeds its own rendering target /// \brief Create a new context that embeds its own rendering target
/// ///
@ -81,9 +81,9 @@ public:
/// \param height Back buffer height, in pixels /// \param height Back buffer height, in pixels
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
EaglContext(EaglContext* shared, const ContextSettings& settings, EaglContext(EaglContext* shared, const ContextSettings& settings,
unsigned int width, unsigned int height); unsigned int width, unsigned int height);
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Destructor /// \brief Destructor
/// ///
@ -106,7 +106,7 @@ public:
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
virtual void display(); virtual void display();
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Enable or disable vertical synchronization /// \brief Enable or disable vertical synchronization
/// ///
@ -119,9 +119,9 @@ public:
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
virtual void setVerticalSyncEnabled(bool enabled); virtual void setVerticalSyncEnabled(bool enabled);
protected: protected:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Activate the context as the current target /// \brief Activate the context as the current target
/// for rendering /// for rendering
@ -130,9 +130,9 @@ protected:
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
virtual bool makeCurrent(); virtual bool makeCurrent();
private: private:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Create the context /// \brief Create the context
/// ///
@ -144,9 +144,9 @@ private:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void createContext(EaglContext* shared, void createContext(EaglContext* shared,
const WindowImplUIKit* window, const WindowImplUIKit* window,
unsigned int bitsPerPixel, unsigned int bitsPerPixel,
const ContextSettings& settings); const ContextSettings& settings);
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
// Member data // Member data
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
@ -157,9 +157,9 @@ private:
bool m_vsyncEnabled; ///< Vertical sync activation flag bool m_vsyncEnabled; ///< Vertical sync activation flag
Clock m_clock; ///< Measures the elapsed time for the fake v-sync implementation Clock m_clock; ///< Measures the elapsed time for the fake v-sync implementation
}; };
} // namespace priv } // namespace priv
} // namespace sf } // namespace sf
#endif // SFML_EAGLCONTEXT_HPP #endif // SFML_EAGLCONTEXT_HPP

View File

@ -56,7 +56,7 @@ m_clock ()
m_context = [[EAGLContext alloc] initWithAPI:kEAGLRenderingAPIOpenGLES1]; m_context = [[EAGLContext alloc] initWithAPI:kEAGLRenderingAPIOpenGLES1];
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
EaglContext::EaglContext(EaglContext* shared, const ContextSettings& settings, EaglContext::EaglContext(EaglContext* shared, const ContextSettings& settings,
const WindowImpl* owner, unsigned int bitsPerPixel) : const WindowImpl* owner, unsigned int bitsPerPixel) :
@ -74,7 +74,7 @@ m_clock ()
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
EaglContext::EaglContext(EaglContext* shared, const ContextSettings& settings, EaglContext::EaglContext(EaglContext* shared, const ContextSettings& settings,
unsigned int width, unsigned int height) : unsigned int width, unsigned int height) :
m_context (nil), m_context (nil),
m_framebuffer (0), m_framebuffer (0),
@ -96,7 +96,7 @@ EaglContext::~EaglContext()
// Activate the context, so that we can destroy the buffers // Activate the context, so that we can destroy the buffers
EAGLContext* previousContext = [EAGLContext currentContext]; EAGLContext* previousContext = [EAGLContext currentContext];
[EAGLContext setCurrentContext:m_context]; [EAGLContext setCurrentContext:m_context];
// Destroy the buffers // Destroy the buffers
if (m_framebuffer) if (m_framebuffer)
glDeleteFramebuffersOES(1, &m_framebuffer); glDeleteFramebuffersOES(1, &m_framebuffer);
@ -161,7 +161,7 @@ void EaglContext::recreateRenderBuffers(SFView* glView)
[EAGLContext setCurrentContext:previousContext]; [EAGLContext setCurrentContext:previousContext];
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
bool EaglContext::makeCurrent() bool EaglContext::makeCurrent()
{ {
@ -193,11 +193,11 @@ void EaglContext::setVerticalSyncEnabled(bool enabled)
m_vsyncEnabled = enabled; m_vsyncEnabled = enabled;
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void EaglContext::createContext(EaglContext* shared, void EaglContext::createContext(EaglContext* shared,
const WindowImplUIKit* window, const WindowImplUIKit* window,
unsigned int bitsPerPixel, unsigned int bitsPerPixel,
const ContextSettings& settings) const ContextSettings& settings)
{ {
// Save the settings // Save the settings

View File

@ -73,7 +73,7 @@ namespace
// Save the delegate instance // Save the delegate instance
delegateInstance = self; delegateInstance = self;
// Instanciate the motion manager // Instantiate the motion manager
self.motionManager = [[CMMotionManager alloc] init]; self.motionManager = [[CMMotionManager alloc] init];
// Register orientation changes notifications // Register orientation changes notifications

View File

@ -57,7 +57,7 @@ public:
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
WindowImplUIKit(WindowHandle handle); WindowImplUIKit(WindowHandle handle);
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Create the window implementation /// \brief Create the window implementation
/// ///
@ -68,7 +68,7 @@ public:
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
WindowImplUIKit(VideoMode mode, const String& title, unsigned long style, const ContextSettings& settings); WindowImplUIKit(VideoMode mode, const String& title, unsigned long style, const ContextSettings& settings);
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Destructor /// \brief Destructor
/// ///
@ -82,7 +82,7 @@ public:
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
virtual WindowHandle getSystemHandle() const; virtual WindowHandle getSystemHandle() const;
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Get the position of the window /// \brief Get the position of the window
/// ///
@ -177,7 +177,7 @@ public:
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
/// \brief Notify an event /// \brief Notify an event
/// ///
/// \param event Evenet to forward /// \param event Event to forward
/// ///
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void forwardEvent(Event event); void forwardEvent(Event event);
@ -216,9 +216,9 @@ private:
SFViewController* m_viewController; ///< Controller attached to the view SFViewController* m_viewController; ///< Controller attached to the view
bool m_hasFocus; ///< Current focus state of the window bool m_hasFocus; ///< Current focus state of the window
}; };
} // namespace priv } // namespace priv
} // namespace sf } // namespace sf

View File

@ -47,7 +47,7 @@ WindowImplUIKit::WindowImplUIKit(WindowHandle handle)
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
WindowImplUIKit::WindowImplUIKit(VideoMode mode, WindowImplUIKit::WindowImplUIKit(VideoMode mode,
const String& title, const String& title,
unsigned long style, unsigned long style,
const ContextSettings& /*settings*/) const ContextSettings& /*settings*/)
{ {
@ -67,7 +67,7 @@ WindowImplUIKit::WindowImplUIKit(VideoMode mode,
// Assign it to the application delegate // Assign it to the application delegate
[SFAppDelegate getInstance].sfWindow = this; [SFAppDelegate getInstance].sfWindow = this;
// Create the view // Create the view
m_view = [[SFView alloc] initWithFrame:frame]; m_view = [[SFView alloc] initWithFrame:frame];
[m_view resignFirstResponder]; [m_view resignFirstResponder];
@ -96,14 +96,14 @@ void WindowImplUIKit::processEvents()
; ;
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
WindowHandle WindowImplUIKit::getSystemHandle() const WindowHandle WindowImplUIKit::getSystemHandle() const
{ {
return (__bridge WindowHandle)m_window; return (__bridge WindowHandle)m_window;
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
Vector2i WindowImplUIKit::getPosition() const Vector2i WindowImplUIKit::getPosition() const
{ {
@ -123,7 +123,7 @@ Vector2u WindowImplUIKit::getSize() const
return Vector2u(m_window.frame.size.width, m_window.frame.size.height); return Vector2u(m_window.frame.size.width, m_window.frame.size.height);
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void WindowImplUIKit::setSize(const Vector2u& size) void WindowImplUIKit::setSize(const Vector2u& size)
{ {
@ -136,35 +136,35 @@ void WindowImplUIKit::setSize(const Vector2u& size)
[[UIApplication sharedApplication] setStatusBarOrientation:UIInterfaceOrientationPortrait]; [[UIApplication sharedApplication] setStatusBarOrientation:UIInterfaceOrientationPortrait];
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void WindowImplUIKit::setTitle(const String& title) void WindowImplUIKit::setTitle(const String& title)
{ {
// Not applicable // Not applicable
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void WindowImplUIKit::setIcon(unsigned int width, unsigned int height, const Uint8* pixels) void WindowImplUIKit::setIcon(unsigned int width, unsigned int height, const Uint8* pixels)
{ {
// Not applicable // Not applicable
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void WindowImplUIKit::setVisible(bool visible) void WindowImplUIKit::setVisible(bool visible)
{ {
// Not applicable // Not applicable
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void WindowImplUIKit::setMouseCursorVisible(bool visible) void WindowImplUIKit::setMouseCursorVisible(bool visible)
{ {
// Not applicable // Not applicable
} }
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
void WindowImplUIKit::setKeyRepeatEnabled(bool enabled) void WindowImplUIKit::setKeyRepeatEnabled(bool enabled)
{ {
@ -213,7 +213,7 @@ void WindowImplUIKit::setVirtualKeyboardVisible(bool visible)
else else
[m_view resignFirstResponder]; [m_view resignFirstResponder];
} }
} // namespace priv } // namespace priv
} // namespace sf } // namespace sf