Merge pull request #1401 from konstin/master

running whitespace.py
This commit is contained in:
auriamg 2014-07-09 20:25:58 -04:00
commit 95c59b8d51
17 changed files with 26 additions and 26 deletions

View File

@ -114,7 +114,7 @@ Achievement * AchievementsStatus::getAchievement(uint32_t id)
// ----------------------------------------------------------------------------
/** Synchronises the achievements between local and online usage. It takes
* the list of online achievements, and marks them all to be achieved
* the list of online achievements, and marks them all to be achieved
* locally. Then it issues 'achieved' requests to the server for all local
* achievements that are not set online.
*/

View File

@ -87,7 +87,7 @@ public:
// ============================================================================
/** List of all messages. */
std::priority_queue<Message*, std::vector<Message*>,
std::priority_queue<Message*, std::vector<Message*>,
CompareMessages> g_all_messages;
/** How long the current message has been displayed. The special value
@ -139,7 +139,7 @@ void add(MessageType mt, const irr::core::stringw &message)
} // add
// ----------------------------------------------------------------------------
/** Update function called from the GUIEngine to handle displaying of the
/** Update function called from the GUIEngine to handle displaying of the
* messages. It will make sure that each message is shown for a certain
* amount of time, before it is discarded and the next message (if any)
* is displayed.
@ -166,7 +166,7 @@ void update(float dt)
}
Message *current = g_all_messages.top();
GUIEngine::getSkin()->drawMessage(g_container, g_area,
GUIEngine::getSkin()->drawMessage(g_container, g_area,
current->getRenderType());
gui::ScalableFont *font = GUIEngine::getFont();

View File

@ -322,7 +322,7 @@ namespace Online
// Check if we are asked to abort the download. If so, signal this
// back to libcurl by returning a non-zero status.
if( (request_manager->getAbort() || request->isCancelled()) &&
if( (request_manager->getAbort() || request->isCancelled()) &&
request->isAbortable() )
{
// Indicates to abort the current download, which means that this

View File

@ -196,7 +196,7 @@ namespace Online
// Even if no achievements were sent, we have to call sync
// in order to upload local achievements to the server
input->get("achieved", &achieved_string);
std::vector<uint32_t> achieved_ids =
std::vector<uint32_t> achieved_ids =
StringUtils::splitToUInt(achieved_string, ' ');
PlayerManager::getCurrentAchievementsStatus()->sync(achieved_ids);
m_profile->fetchFriends();

View File

@ -220,7 +220,7 @@ namespace Online
} // while
// Signal that the request manager can now be deleted.
// We signal this even before cleaning up memory, since there's no
// We signal this even before cleaning up memory, since there's no
// need to keep the user waiting for STK to exit.
me->setCanBeDeleted();

View File

@ -67,7 +67,7 @@ namespace Online
* manager which might be accessed if a download just finished before the
* abort). On executing the quit request, the request manager will set
* a flag that it is ready to be deleted (using the CanBeDeleted class).
* The main thread will wait for a certain amount of time for the
* The main thread will wait for a certain amount of time for the
* RequestManager to be ready to be deleted (i.e. the sign-out and quit
* request have been processes), before deleting the RequestManager.
* Typically the RequestManager will finish while the rest of stk is

View File

@ -84,7 +84,7 @@ Physics::~Physics()
// ----------------------------------------------------------------------------
/** Adds a kart to the physics engine.
* This adds the rigid body and the vehicle but only if the kart is not
* This adds the rigid body and the vehicle but only if the kart is not
* already in the physics world.
* \param kart The kart to add.
* \param vehicle The raycast vehicle object.

View File

@ -304,7 +304,7 @@ bool TriangleMesh::castRay(const btVector3 &from, const btVector3 &to,
btCollisionWorld::ClosestRayResultCallback result(from, to);
/** A special ray result class that stores the index of the triangle
/** A special ray result class that stores the index of the triangle
* that was hit. */
class MaterialRayResult : public btCollisionWorld::ClosestRayResultCallback
{
@ -351,7 +351,7 @@ bool TriangleMesh::castRay(const btVector3 &from, const btVector3 &to,
// the normal of the triangle interpolate the normal at the
// hit position based on the three normals of the triangle.
if(interpolate_normal)
*normal = getInterpolatedNormal(ray_callback.m_index,
*normal = getInterpolatedNormal(ray_callback.m_index,
ray_callback.m_hitPointWorld);
else
*normal = ray_callback.m_hitNormalWorld;

View File

@ -452,7 +452,7 @@ bool UserInfoDialog::onEscapePressed()
void UserInfoDialog::onUpdate(float dt)
{
if(m_processing)
if(m_processing)
m_info_widget->setText(StringUtils::loadingDots(_("Processing")), false);
//If we want to open the registration dialog, we need to close this one first

View File

@ -160,8 +160,8 @@ void OnlineProfileAchievements::onUpdate(float delta)
if (!m_visiting_profile->isReady())
{
// This will display an increasing number of dots while waiting.
m_achievements_list_widget->renameItem("loading",
StringUtils::loadingDots(_("Fetching achievements")));
m_achievements_list_widget->renameItem("loading",
StringUtils::loadingDots(_("Fetching achievements")));
return;
}

View File

@ -84,7 +84,7 @@ void OnlineProfileFriends::init()
m_visiting_profile->fetchFriends();
m_waiting_for_friends = true;
m_friends_list_widget->clear();
m_friends_list_widget->addItem("loading",
m_friends_list_widget->addItem("loading",
StringUtils::loadingDots(_("Fetching friends")));
} // init

View File

@ -275,7 +275,7 @@ void OnlineUserSearch::onUpdate(float dt)
}
else
{
m_user_list_widget->renameItem("loading",
m_user_list_widget->renameItem("loading",
StringUtils::loadingDots(_("Searching")) );
}
}

View File

@ -84,7 +84,7 @@ private:
/** Height of the digit font. */
int m_font_height;
/** Animation state: none, getting smaller (old value),
/** Animation state: none, getting smaller (old value),
* getting bigger (new number). */
enum AnimationState {AS_NONE, AS_SMALLER, AS_BIGGER};
std::vector<AnimationState> m_animation_states;

View File

@ -89,7 +89,7 @@ void RegisterScreen::init()
getWidget<CheckBoxWidget>("online")->setVisible(true);
getWidget<LabelWidget>("label_online")->setVisible(true);
onDialogClose();
bool online = UserConfigParams::m_internet_status
bool online = UserConfigParams::m_internet_status
!= Online::RequestManager::IPERM_NOT_ALLOWED;
getWidget<CheckBoxWidget>("online")->setState(online);
makeEntryFieldsVisible(online);
@ -108,7 +108,7 @@ void RegisterScreen::setRename(PlayerProfile *player)
*/
void RegisterScreen::onDialogClose()
{
bool online = UserConfigParams::m_internet_status
bool online = UserConfigParams::m_internet_status
!= Online::RequestManager::IPERM_NOT_ALLOWED;
getWidget<CheckBoxWidget>("online")->setState(online);
makeEntryFieldsVisible(online);

View File

@ -57,7 +57,7 @@ void TerrainInfo::update(const Vec3 &from)
to.setY(-10000.0f);
const TriangleMesh &tm = World::getWorld()->getTrack()->getTriangleMesh();
tm.castRay(from, to, &m_hit_point, &m_material, &m_normal,
tm.castRay(from, to, &m_hit_point, &m_material, &m_normal,
/*interpolate*/false);
} // update
//-----------------------------------------------------------------------------

View File

@ -54,9 +54,9 @@ public:
Log::verbose("Thread", "Start waiting %lf", start);
while(1)
{
if(m_can_be_deleted.getAtomic())
if(m_can_be_deleted.getAtomic())
{
Log::verbose("Thread",
Log::verbose("Thread",
"Waited %lf seconds for thread to become deleteable.",
StkTime::getRealTime()-start);
Log::verbose("Thread", "Stop waiting %lf", StkTime::getRealTime());
@ -67,7 +67,7 @@ public:
{
Log::verbose("Thread", "Stop waiting %lf", StkTime::getRealTime());
Log::verbose("Thread", "Waited for more than %f seconds for "
"thread to become deleteable",
"thread to become deleteable",
waiting_time);
return false;
}
@ -76,4 +76,4 @@ public:
// ------------------------------------------------------------------------
}; // CanBeDeleted
#endif
#endif

View File

@ -531,9 +531,9 @@ namespace StringUtils
*/
irr::core::stringw loadingDots(float interval, int max_dots)
{
int nr_dots = int(floor(StkTime::getRealTime() / interval))
int nr_dots = int(floor(StkTime::getRealTime() / interval))
% (max_dots + 1);
return irr::core::stringw((std::string(nr_dots, '.') +
return irr::core::stringw((std::string(nr_dots, '.') +
std::string(max_dots - nr_dots, ' ')).c_str());
} // loadingDots