Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Tor Browser
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
The Tor Project
Applications
Tor Browser
Commits
5154bd18
Verified
Commit
5154bd18
authored
1 year ago
by
cypherpunks1
Committed by
Pier Angelo Vendrame
6 months ago
Browse files
Options
Downloads
Patches
Plain Diff
Bug 41791: Omit the source URL when copying page contents to the clipboard
parent
c40a7c76
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!1135
Bug 43084: Rebased stable onto 115.15.0esr
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dom/base/nsCopySupport.cpp
+2
-0
2 additions, 0 deletions
dom/base/nsCopySupport.cpp
widget/windows/nsDataObj.cpp
+4
-0
4 additions, 0 deletions
widget/windows/nsDataObj.cpp
with
6 additions
and
0 deletions
dom/base/nsCopySupport.cpp
+
2
−
0
View file @
5154bd18
...
...
@@ -284,6 +284,7 @@ static nsresult CreateTransferable(
NS_ENSURE_SUCCESS
(
rv
,
rv
);
}
#if !defined(BASE_BROWSER_VERSION)
// Try and get source URI of the items that are being dragged
nsIURI
*
uri
=
aDocument
.
GetDocumentURI
();
if
(
uri
)
{
...
...
@@ -304,6 +305,7 @@ static nsresult CreateTransferable(
NS_ENSURE_SUCCESS
(
rv
,
rv
);
}
}
#endif
}
else
{
if
(
!
aEncodedDocumentWithContext
.
mSerializationForTextUnicode
.
IsEmpty
())
{
// Add the unicode DataFlavor to the transferable
...
...
This diff is collapsed.
Click to expand it.
widget/windows/nsDataObj.cpp
+
4
−
0
View file @
5154bd18
...
...
@@ -520,11 +520,13 @@ nsDataObj::nsDataObj(nsIURI* uri)
m_enumFE
=
new
CEnumFormatEtc
();
m_enumFE
->
AddRef
();
#if !defined(BASE_BROWSER_VERSION)
if
(
uri
)
{
// A URI was obtained, so pass this through to the DataObject
// so it can create a SourceURL for CF_HTML flavour
uri
->
GetSpec
(
mSourceURL
);
}
#endif
}
//-----------------------------------------------------
// destruction
...
...
@@ -1978,6 +1980,7 @@ nsresult nsDataObj ::BuildPlatformHTML(const char* inOurHTML,
*
outPlatformHTML
=
nullptr
;
nsDependentCString
inHTMLString
(
inOurHTML
);
#if !defined(BASE_BROWSER_VERSION)
// Do we already have mSourceURL from a drag?
if
(
mSourceURL
.
IsEmpty
())
{
nsAutoString
url
;
...
...
@@ -1985,6 +1988,7 @@ nsresult nsDataObj ::BuildPlatformHTML(const char* inOurHTML,
AppendUTF16toUTF8
(
url
,
mSourceURL
);
}
#endif
constexpr
auto
kStartHTMLPrefix
=
"Version:0.9
\r\n
StartHTML:"
_ns
;
constexpr
auto
kEndHTMLPrefix
=
"
\r\n
EndHTML:"
_ns
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment