瀏覽代碼

Remove love.dropbegan and love.dropcompleted callbacks. Closes #1908

They don't do what most people might assume they do (they happen at the same time as the user completes a drag-and-drop operation and they surround the dropfile events, instead of starting when the user initiates the operation). Also their functionality can be replicated without needing dedicated love event callbacks.
Sasha Szpakowski 2 年之前
父節點
當前提交
c4aaab6bf0
共有 3 個文件被更改,包括 0 次插入13 次删除
  1. 0 1
      changes.txt
  2. 0 6
      src/modules/event/sdl/Event.cpp
  3. 0 6
      src/modules/love/callbacks.lua

+ 0 - 1
changes.txt

@@ -11,7 +11,6 @@ Released: N/A
 * Added love.event.restart(optionalvalue). A new love.restart field will contain the value after restarting.
 * Added love.event.restart(optionalvalue). A new love.restart field will contain the value after restarting.
 * Added love.system.getPreferredLocales.
 * Added love.system.getPreferredLocales.
 * Added love.localechanged callback.
 * Added love.localechanged callback.
-* Added love.dropbegan and love.dropcompleted callbacks.
 * Added love.audiodisconnected callback.
 * Added love.audiodisconnected callback.
 * Added love.filesystem.mountFullPath and love.filesystem.unmountFullPath, including opt-in mount-for-write support.
 * Added love.filesystem.mountFullPath and love.filesystem.unmountFullPath, including opt-in mount-for-write support.
 * Added love.filesystem.mountCommonPath, unmountCommonPath, and getFullCommonPath.
 * Added love.filesystem.mountCommonPath, unmountCommonPath, and getFullCommonPath.

+ 0 - 6
src/modules/event/sdl/Event.cpp

@@ -414,12 +414,6 @@ Message *Event::convert(const SDL_Event &e)
 		}
 		}
 		SDL_free(e.drop.file);
 		SDL_free(e.drop.file);
 		break;
 		break;
-	case SDL_DROPBEGIN:
-		msg = new Message("dropbegan");
-		break;
-	case SDL_DROPCOMPLETE:
-		msg = new Message("dropcompleted");
-		break;
 	case SDL_QUIT:
 	case SDL_QUIT:
 	case SDL_APP_TERMINATING:
 	case SDL_APP_TERMINATING:
 		msg = new Message("quit");
 		msg = new Message("quit");

+ 0 - 6
src/modules/love/callbacks.lua

@@ -115,12 +115,6 @@ function love.createhandlers()
 		directorydropped = function (dir)
 		directorydropped = function (dir)
 			if love.directorydropped then return love.directorydropped(dir) end
 			if love.directorydropped then return love.directorydropped(dir) end
 		end,
 		end,
-		dropbegan = function ()
-			if love.dropbegan then return love.dropbegan() end
-		end,
-		dropcompleted = function ()
-			if love.dropcompleted then return love.dropcompleted() end
-		end,
 		lowmemory = function ()
 		lowmemory = function ()
 			if love.lowmemory then love.lowmemory() end
 			if love.lowmemory then love.lowmemory() end
 			collectgarbage()
 			collectgarbage()