Browse Source

Added contributor credit. Use "unsigned" data type consistently since it's guaranteed to be 32bit on the platforms Urho compiles on.

Lasse Öörni 9 years ago
parent
commit
642f09817e
4 changed files with 7 additions and 5 deletions
  1. 1 0
      Docs/Urho3D.dox
  2. 1 0
      README.md
  3. 2 2
      Source/Urho3D/IO/FileWatcher.cpp
  4. 3 3
      Source/Urho3D/Resource/Image.cpp

+ 1 - 0
Docs/Urho3D.dox

@@ -118,6 +118,7 @@ Urho3D development, contributions and bugfixes by:
 - att
 - celeron55
 - cosmy1
+- damu
 - dragonCASTjosh
 - feltech
 - hdunderscore

+ 1 - 0
README.md

@@ -70,6 +70,7 @@ Urho3D development, contributions and bugfixes by:
 - att
 - celeron55
 - cosmy1
+- damu
 - dragonCASTjosh
 - feltech
 - hdunderscore

+ 2 - 2
Source/Urho3D/IO/FileWatcher.cpp

@@ -114,7 +114,7 @@ bool FileWatcher::StartWatching(const String& pathName, bool watchSubDirs)
     }
 #elif defined(__linux__)
     int flags = IN_CREATE | IN_DELETE | IN_MODIFY | IN_MOVED_FROM | IN_MOVED_TO;
-    int handle = inotify_add_watch(watchHandle_, pathName.CString(), (uint32_t)flags);
+    int handle = inotify_add_watch(watchHandle_, pathName.CString(), (unsigned)flags);
 
     if (handle < 0)
     {
@@ -140,7 +140,7 @@ bool FileWatcher::StartWatching(const String& pathName, bool watchSubDirs)
                 // Don't watch ./ or ../ sub-directories
                 if (!subDirFullPath.EndsWith("./"))
                 {
-                    handle = inotify_add_watch(watchHandle_, subDirFullPath.CString(), (uint32_t)flags);
+                    handle = inotify_add_watch(watchHandle_, subDirFullPath.CString(), (unsigned)flags);
                     if (handle < 0)
                         URHO3D_LOGERROR("Failed to start watching subdirectory path " + subDirFullPath);
                     else

+ 3 - 3
Source/Urho3D/Resource/Image.cpp

@@ -1116,9 +1116,9 @@ void Image::ClearInt(unsigned uintColor)
 
     if (components_ == 4)
     {
-        uint32_t color = uintColor;
-        uint32_t* data = (uint32_t*)GetData();
-        uint32_t* data_end = (uint32_t*)(GetData() + width_ * height_ * depth_ * components_);
+        unsigned color = uintColor;
+        unsigned* data = (unsigned*)GetData();
+        unsigned* data_end = (unsigned*)(GetData() + width_ * height_ * depth_ * components_);
         for (; data < data_end; ++data)
             *data = color;
     }