25 lines
660 B
C#
25 lines
660 B
C#
using Cryville.Crtr.UI;
|
|
using System;
|
|
|
|
namespace Cryville.Crtr.Browsing.Actions {
|
|
internal class ImportResourceAction : IResourceAction {
|
|
readonly IResourceManager _destination;
|
|
public ImportResourceAction(IResourceManager destination) {
|
|
_destination = destination;
|
|
}
|
|
|
|
public string Name { get { return "Import"; } }
|
|
public int Priority { get { return 0; } }
|
|
|
|
public bool CanInvoke(Uri uri, IResourceMeta resource) {
|
|
throw new NotImplementedException();
|
|
}
|
|
public void Invoke(Uri uri, IResourceMeta resource) {
|
|
if (_destination.ImportFrom(uri))
|
|
Popup.Create("Import succeeded");
|
|
else
|
|
Popup.Create("Import failed");
|
|
}
|
|
}
|
|
}
|