Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions dotnet/src/webdriver/BiDi/BiDi.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,13 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Json;
using OpenQA.Selenium.BiDi.Json.Converters;
using System;
using System.Text.Json;
using System.Text.Json.Serialization;
using System.Threading;
using System.Threading.Tasks;
using OpenQA.Selenium.BiDi.Communication;
using OpenQA.Selenium.BiDi.Communication.Json;
using OpenQA.Selenium.BiDi.Communication.Json.Converters;

namespace OpenQA.Selenium.BiDi;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication.Transport;
using OpenQA.Selenium.Internal.Logging;
using System;
using System.Collections.Concurrent;
Expand All @@ -28,7 +27,7 @@
using System.Threading;
using System.Threading.Tasks;

namespace OpenQA.Selenium.BiDi.Communication;
namespace OpenQA.Selenium.BiDi;

public sealed class Broker : IAsyncDisposable
{
Expand Down Expand Up @@ -214,13 +213,13 @@ public async Task<Subscription> SubscribeAsync<TEventArgs>(string eventName, Fun
}
}

public async Task UnsubscribeAsync(Session.Subscription subscription, EventHandler eventHandler)
public async Task UnsubscribeAsync(Subscription subscription)
{
var eventHandlers = _eventHandlers[eventHandler.EventName];
var eventHandlers = _eventHandlers[subscription.EventHandler.EventName];

eventHandlers.Remove(eventHandler);
eventHandlers.Remove(subscription.EventHandler);

await _bidi.SessionModule.UnsubscribeAsync([subscription]).ConfigureAwait(false);
await _bidi.SessionModule.UnsubscribeAsync([subscription.SubscriptionId]).ConfigureAwait(false);
}

public async ValueTask DisposeAsync()
Expand Down
1 change: 0 additions & 1 deletion dotnet/src/webdriver/BiDi/Browser/BrowserModule.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using System.Threading.Tasks;

namespace OpenQA.Selenium.BiDi.Browser;
Expand Down
2 changes: 1 addition & 1 deletion dotnet/src/webdriver/BiDi/Browser/ClientWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Text.Json.Serialization;

namespace OpenQA.Selenium.BiDi.Browser;
Expand Down
2 changes: 1 addition & 1 deletion dotnet/src/webdriver/BiDi/Browser/ClientWindowInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Text.Json.Serialization;

namespace OpenQA.Selenium.BiDi.Browser;
Expand Down
2 changes: 0 additions & 2 deletions dotnet/src/webdriver/BiDi/Browser/CloseCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.Browser;

internal sealed class CloseCommand()
Expand Down
2 changes: 0 additions & 2 deletions dotnet/src/webdriver/BiDi/Browser/CreateUserContextCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.Browser;

internal sealed class CreateUserContextCommand(CreateUserContextParameters @params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using System.Collections.Generic;

namespace OpenQA.Selenium.BiDi.Browser;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using System.Collections.Generic;

namespace OpenQA.Selenium.BiDi.Browser;
Expand Down
2 changes: 0 additions & 2 deletions dotnet/src/webdriver/BiDi/Browser/RemoveUserContextCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.Browser;

internal sealed class RemoveUserContextCommand(RemoveUserContextParameters @params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using System.Collections.Generic;
using System.Text.Json.Serialization;

Expand Down
2 changes: 0 additions & 2 deletions dotnet/src/webdriver/BiDi/Browser/UserContextInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.Browser;

public record UserContextInfo(UserContext UserContext) : EmptyResult;
2 changes: 0 additions & 2 deletions dotnet/src/webdriver/BiDi/BrowsingContext/ActivateCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.BrowsingContext;

internal sealed class ActivateCommand(ActivateParameters @params)
Expand Down
3 changes: 1 addition & 2 deletions dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,8 @@
// under the License.
// </copyright>

using System.Threading.Tasks;
using System;
using OpenQA.Selenium.BiDi.Communication;
using System.Threading.Tasks;

namespace OpenQA.Selenium.BiDi.BrowsingContext;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@

using System;
using System.Threading.Tasks;
using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.BrowsingContext;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System;
using System.Text.Json.Serialization;

Expand Down
2 changes: 0 additions & 2 deletions dotnet/src/webdriver/BiDi/BrowsingContext/CloseCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.BrowsingContext;

internal sealed class CloseCommand(CloseParameters @params)
Expand Down
3 changes: 1 addition & 2 deletions dotnet/src/webdriver/BiDi/BrowsingContext/CreateCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Text.Json.Serialization;

namespace OpenQA.Selenium.BiDi.BrowsingContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic;
using OpenQA.Selenium.BiDi.Json.Converters.Polymorphic;
using System;
using System.Text.Json.Serialization;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using System.Collections.Generic;

namespace OpenQA.Selenium.BiDi.BrowsingContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.BrowsingContext;

internal sealed class HandleUserPromptCommand(HandleUserPromptParameters @params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using System.Collections.Generic;

namespace OpenQA.Selenium.BiDi.BrowsingContext;
Expand Down
2 changes: 1 addition & 1 deletion dotnet/src/webdriver/BiDi/BrowsingContext/Locator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Text.Json.Serialization;

namespace OpenQA.Selenium.BiDi.BrowsingContext;
Expand Down
3 changes: 1 addition & 2 deletions dotnet/src/webdriver/BiDi/BrowsingContext/NavigateCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Text.Json.Serialization;

namespace OpenQA.Selenium.BiDi.BrowsingContext;
Expand Down
2 changes: 1 addition & 1 deletion dotnet/src/webdriver/BiDi/BrowsingContext/Navigation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Text.Json.Serialization;

namespace OpenQA.Selenium.BiDi.BrowsingContext;
Expand Down
3 changes: 1 addition & 2 deletions dotnet/src/webdriver/BiDi/BrowsingContext/PrintCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System;
using System.Collections.Generic;
using System.Text.Json.Serialization;
Expand Down
2 changes: 0 additions & 2 deletions dotnet/src/webdriver/BiDi/BrowsingContext/ReloadCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.BrowsingContext;

internal sealed class ReloadCommand(ReloadParameters @params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.BrowsingContext;

internal sealed class SetViewportCommand(SetViewportParameters @params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.BrowsingContext;

internal sealed class TraverseHistoryCommand(TraverseHistoryParameters @params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Text.Json.Serialization;

namespace OpenQA.Selenium.BiDi.BrowsingContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,9 @@
// under the License.
// </copyright>

using System;
using System.Text.Json.Serialization;

namespace OpenQA.Selenium.BiDi.Communication;
namespace OpenQA.Selenium.BiDi;

public abstract class Command
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

using System;

namespace OpenQA.Selenium.BiDi.Communication;
namespace OpenQA.Selenium.BiDi;

public abstract class CommandOptions
{
Expand Down
1 change: 0 additions & 1 deletion dotnet/src/webdriver/BiDi/Emulation/EmulationModule.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
// </copyright>

using System.Threading.Tasks;
using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.Emulation;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Collections.Generic;
using System.Text.Json.Serialization;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@

using System.Collections.Generic;
using System.Text.Json.Serialization;
using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.Emulation;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@

using System.Collections.Generic;
using System.Text.Json.Serialization;
using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.Emulation;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using OpenQA.Selenium.BiDi.Communication.Json.Converters;
using OpenQA.Selenium.BiDi.Json.Converters;
using System.Collections.Generic;
using System.Text.Json.Serialization;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@

using System.Collections.Generic;
using System.Text.Json.Serialization;
using OpenQA.Selenium.BiDi.Communication;

namespace OpenQA.Selenium.BiDi.Emulation;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using System.Collections.Generic;
using System.Text.Json.Serialization;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
// under the License.
// </copyright>

using OpenQA.Selenium.BiDi.Communication;
using System.Collections.Generic;
using System.Text.Json.Serialization;

Expand Down
Loading