2014-10-14 13:11:37 +00:00
|
|
|
/*
|
|
|
|
* This file is part of the Colobot: Gold Edition source code
|
2020-07-07 08:19:36 +00:00
|
|
|
* Copyright (C) 2001-2020, Daniel Roux, EPSITEC SA & TerranovaTeam
|
2015-08-22 14:40:02 +00:00
|
|
|
* http://epsitec.ch; http://colobot.info; http://github.com/colobot
|
2014-10-14 13:11:37 +00:00
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
* See the GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see http://gnu.org/licenses
|
|
|
|
*/
|
2012-07-15 17:17:49 +00:00
|
|
|
|
2012-08-11 16:39:16 +00:00
|
|
|
/**
|
2016-07-24 12:38:49 +00:00
|
|
|
* \file common/system/system_other.h
|
2012-08-11 16:39:16 +00:00
|
|
|
* \brief Fallback code for other systems
|
|
|
|
*/
|
2012-07-15 17:17:49 +00:00
|
|
|
|
2016-07-24 12:38:49 +00:00
|
|
|
#include "common/system/system.h"
|
2012-07-15 17:17:49 +00:00
|
|
|
|
2013-03-22 17:19:53 +00:00
|
|
|
#include <SDL.h>
|
2012-07-15 17:17:49 +00:00
|
|
|
|
|
|
|
#include <iostream>
|
|
|
|
|
2015-09-29 19:35:29 +00:00
|
|
|
//@colobot-lint-exclude UndefinedFunctionRule
|
2012-07-15 17:17:49 +00:00
|
|
|
|
|
|
|
struct SystemTimeStamp
|
|
|
|
{
|
|
|
|
Uint32 sdlTicks;
|
|
|
|
|
|
|
|
SystemTimeStamp()
|
|
|
|
{
|
|
|
|
sdlTicks = 0;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|
2013-03-23 23:03:37 +00:00
|
|
|
class CSystemUtilsOther : public CSystemUtils
|
|
|
|
{
|
|
|
|
public:
|
2015-08-17 19:53:28 +00:00
|
|
|
void Init() override;
|
|
|
|
SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
2012-07-15 17:17:49 +00:00
|
|
|
|
2017-08-06 10:03:28 +00:00
|
|
|
void InterpolateTimeStamp(SystemTimeStamp *dst, SystemTimeStamp *a, SystemTimeStamp *b, float i) override;
|
2015-08-17 19:53:28 +00:00
|
|
|
void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
|
|
|
long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
2015-04-27 16:35:41 +00:00
|
|
|
|
2015-08-17 19:53:28 +00:00
|
|
|
void Usleep(int usec) override;
|
2013-03-23 23:03:37 +00:00
|
|
|
};
|
2013-05-26 15:47:54 +00:00
|
|
|
|
2015-09-29 19:35:29 +00:00
|
|
|
//@end-colobot-lint-exclude
|