diff options
author | Marius Ungureanu <marius.ungureanu@xamarin.com> | 2019-09-24 21:49:03 +0300 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2019-09-24 21:49:02 +0300 |
commit | 394d8d1f2155a8cd162c3a0e2c0d9a4949af5c50 (patch) | |
tree | 1d19785c8d7fa5f036089b312aac681dba581fb4 /mcs/class/System | |
parent | 8f8596761250d15d64a983d34f7de09645601d16 (diff) |
Add RenamedEvent* to FSW sources from CoreFX (#16755)
* Add RenamedEvent* to FSW sources from CoreFX
Fixes #16486 - This was only partially fixed until now
* [csproj] Update project files
* Add test files which test these code paths on corefx
* Remove old RenamedEvent* files
Diffstat (limited to 'mcs/class/System')
-rw-r--r-- | mcs/class/System/System.IO/RenamedEventArgs.cs | 66 | ||||
-rw-r--r-- | mcs/class/System/System.IO/RenamedEventHandler.cs | 33 | ||||
-rw-r--r-- | mcs/class/System/System.csproj | 5 | ||||
-rw-r--r-- | mcs/class/System/System_xtest.dll.sources | 3 | ||||
-rw-r--r-- | mcs/class/System/common.sources | 4 |
5 files changed, 8 insertions, 103 deletions
diff --git a/mcs/class/System/System.IO/RenamedEventArgs.cs b/mcs/class/System/System.IO/RenamedEventArgs.cs deleted file mode 100644 index 6edf8bea930..00000000000 --- a/mcs/class/System/System.IO/RenamedEventArgs.cs +++ /dev/null @@ -1,66 +0,0 @@ -//
-// System.IO.RenamedEventArgs.cs
-//
-// Author:
-// Tim Coleman (tim@timcoleman.com)
-//
-// Copyright (C) Tim Coleman, 2002
-//
- -// -// Permission is hereby granted, free of charge, to any person obtaining -// a copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to -// permit persons to whom the Software is furnished to do so, subject to -// the following conditions: -// -// The above copyright notice and this permission notice shall be -// included in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -// -
-using System;
-
-namespace System.IO {
- public class RenamedEventArgs : FileSystemEventArgs {
-
- #region Fields
-
- string oldName;
- string oldFullPath;
-
- #endregion // Fields
-
- #region Constructors
-
- public RenamedEventArgs (WatcherChangeTypes changeType, string directory, string name, string oldName)
- : base (changeType, directory, name)
- {
- this.oldName = oldName;
- oldFullPath = Path.Combine (directory, oldName);
- }
-
- #endregion // Constructors
-
- #region Properties
-
- public string OldFullPath {
- get { return oldFullPath; }
- }
-
- public string OldName {
- get { return oldName; }
- }
-
- #endregion // Properties
- }
-}
diff --git a/mcs/class/System/System.IO/RenamedEventHandler.cs b/mcs/class/System/System.IO/RenamedEventHandler.cs deleted file mode 100644 index b58674f867a..00000000000 --- a/mcs/class/System/System.IO/RenamedEventHandler.cs +++ /dev/null @@ -1,33 +0,0 @@ -//
-// System.IO.FileSystemEventHandler.cs
-//
-// Author:
-// Tim Coleman (tim@timcoleman.com)
-//
-// Copyright (C) Tim Coleman, 2002
-// Copyright (C) 2006 Novell, Inc (http://www.novell.com) -// -// Permission is hereby granted, free of charge, to any person obtaining -// a copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to -// permit persons to whom the Software is furnished to do so, subject to -// the following conditions: -// -// The above copyright notice and this permission notice shall be -// included in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -// -
-namespace System.IO {
- - public delegate void RenamedEventHandler (object sender, RenamedEventArgs e);
-}
diff --git a/mcs/class/System/System.csproj b/mcs/class/System/System.csproj index 725075883ab..1fb701c8f39 100644 --- a/mcs/class/System/System.csproj +++ b/mcs/class/System/System.csproj @@ -415,6 +415,9 @@ <Compile Include="..\..\..\external\corefx\src\System.IO.Compression\src\System\IO\Compression\GZipStream.cs" /> <Compile Include="..\..\..\external\corefx\src\System.IO.FileSystem.Watcher\src\System\IO\FileSystemEventArgs.cs" /> <Compile Include="..\..\..\external\corefx\src\System.IO.FileSystem.Watcher\src\System\IO\FileSystemEventHandler.cs" /> + <Compile Include="..\..\..\external\corefx\src\System.IO.FileSystem.Watcher\src\System\IO\FileSystemWatcher.cs" /> + <Compile Include="..\..\..\external\corefx\src\System.IO.FileSystem.Watcher\src\System\IO\RenamedEventArgs.cs" /> + <Compile Include="..\..\..\external\corefx\src\System.IO.FileSystem.Watcher\src\System\IO\RenamedEventHandler.cs" /> <Compile Include="..\..\..\external\corefx\src\System.IO.FileSystem.Watcher\src\System\IO\WaitForChangedResult.cs" /> <Compile Include="..\..\..\external\corefx\src\System.Net.Mail\src\System\Net\Base64Stream.cs" /> <Compile Include="..\..\..\external\corefx\src\System.Net.Mail\src\System\Net\BufferBuilder.cs" /> @@ -870,8 +873,6 @@ <Compile Include="System.IO\InternalBufferOverflowException.cs" /> <Compile Include="System.IO\InvalidDataException.cs" /> <Compile Include="System.IO\NotifyFilters.cs" /> - <Compile Include="System.IO\RenamedEventArgs.cs" /> - <Compile Include="System.IO\RenamedEventHandler.cs" /> <Compile Include="System.IO\WatcherChangeTypes.cs" /> <Compile Include="System.Net.Mail\AlternateView.cs" /> <Compile Include="System.Net.Mail\AlternateViewCollection.cs" /> diff --git a/mcs/class/System/System_xtest.dll.sources b/mcs/class/System/System_xtest.dll.sources index b96253754d5..5e3b7e6c522 100644 --- a/mcs/class/System/System_xtest.dll.sources +++ b/mcs/class/System/System_xtest.dll.sources @@ -113,6 +113,9 @@ System/RemoteExecutorTests.cs # System.IO.FileSystemWatcher ../../../external/corefx/src/System.IO.FileSystem.Watcher/tests/Utility/*.cs +../../../external/corefx/src/System.IO.FileSystem.Watcher/tests/Args.ErrorEventArgs.cs +../../../external/corefx/src/System.IO.FileSystem.Watcher/tests/Args.FileSystemEventArgs.cs +../../../external/corefx/src/System.IO.FileSystem.Watcher/tests/Args.RenamedEventArgs.cs ../../../external/corefx/src/System.IO.FileSystem.Watcher/tests/FileSystemWatcher.cs ../../../external/corefx/src/System.IO.FileSystem.Watcher/tests/FileSystemWatcher.unit.cs ../../../external/corefx/src/Common/tests/System/IO/TempFile.cs diff --git a/mcs/class/System/common.sources b/mcs/class/System/common.sources index eda8e8cdf70..5508c2d2b42 100644 --- a/mcs/class/System/common.sources +++ b/mcs/class/System/common.sources @@ -32,8 +32,6 @@ System.IO/InternalBufferOverflowException.cs System.IO/InvalidDataException.cs System.IO/IODescriptionAttribute.cs System.IO/NotifyFilters.cs -System.IO/RenamedEventArgs.cs -System.IO/RenamedEventHandler.cs System.IO/WatcherChangeTypes.cs System.Net/BasicClient.cs @@ -874,6 +872,8 @@ ReferenceSources/Win32Exception.cs ../../../external/corefx/src/System.IO.FileSystem.Watcher/src/System/IO/FileSystemEventArgs.cs ../../../external/corefx/src/System.IO.FileSystem.Watcher/src/System/IO/FileSystemEventHandler.cs ../../../external/corefx/src/System.IO.FileSystem.Watcher/src/System/IO/FileSystemWatcher.cs +../../../external/corefx/src/System.IO.FileSystem.Watcher/src/System/IO/RenamedEventArgs.cs +../../../external/corefx/src/System.IO.FileSystem.Watcher/src/System/IO/RenamedEventHandler.cs ../../../external/corefx/src/System.IO.FileSystem.Watcher/src/System/IO/WaitForChangedResult.cs ../../../external/corefx/src/System.Runtime.InteropServices/src/System/Security/SecureStringMarshal.cs |