Comments (13)
I still think it has to do with the change you implemented making all data return as a file when datatype file is the only one set. I could be wrong but that's what my gut is telling me. We'll have to look into it further
Yes. I believe what is happening is that it doesn't get sent as text because of the shouldAllowText(). It should then be ignored but is instead sent as a file because of the isFile(item) which checks isDocument(item).
We can remove the isDocument(item) check inside isFile(item). Removing the isDocument will mean .numbers files from iCloud won't work, but we can find another solution for that.
As for the shouldAllow for text and url, that was accidentally left in after a revert commit. I'm not sure if we should remove it or not because I'm not sure if doing that will mean urls are categorized as text
That's my theory right now based off my memory. I can test it out later when I get home.
from flutternativedraganddrop.
@getBoolean Currently working on this. Don't remove the isDocument(item) I would prefer that to work then this issue. We'll figure a way around this problem
from flutternativedraganddrop.
Isn't that how it is supposed to behave? If file is an allowedDataType then all of the other data types will be enabled
from flutternativedraganddrop.
Isn't that how it is supposed to behave? If file is an allowedDataType then all of the other data types will be enabled
Not text file, just text. I would think plain text shouldn't be categorized as a file right?
from flutternativedraganddrop.
Isn't that how it is supposed to behave? If file is an allowedDataType then all of the other data types will be enabled
Not text file, just text. I would think plain text shouldn't be categorized as a file right?
I think if a file is a plaintext file then it is registered as a file. Plaintext should be categorized as text.
Didn't you make it so when only the file data type is enabled that like pdf files would register as the file datatype. Is this causing the text to be registered this way too?
from flutternativedraganddrop.
Isn't that how it is supposed to behave? If file is an allowedDataType then all of the other data types will be enabled
Not text file, just text. I would think plain text shouldn't be categorized as a file right?
I think if a file is a plaintext file then it is registered as a file. Plaintext should be categorized as text.
Didn't you make it so when only the file data type is enabled that like pdf files would register as the file datatype. Is this causing the text to be registered this way too?
Not a file, I mean when you select text from something like the notes app
from flutternativedraganddrop.
So you set the datatype as file and you dropped in text from the notes app and it registered as a file?
from flutternativedraganddrop.
So you set the datatype as file and you dropped in text from the notes app and it registered as a file?
Yes
from flutternativedraganddrop.
I still think it has to do with the change you implemented making all data return as a file when datatype file is the only one set. I could be wrong but that's what my gut is telling me. We'll have to look into it further
from flutternativedraganddrop.
@getBoolean Just want to confirm: when you set the only allowed data type to be a file and you drop a string, the string should return with a datatype of text correct?
from flutternativedraganddrop.
I was able to get text and urls to register as their types when only DropDataType.file
is active:
else if isFile(item) && !item.itemProvider.canLoadObject(ofClass: NSURL.self)
&& !item.itemProvider.canLoadObject(ofClass: String.self){
...
}
from flutternativedraganddrop.
Fixed text from being dropped as a file in #9
from flutternativedraganddrop.
Fixed text data type of strings when file data type is files
from flutternativedraganddrop.
Related Issues (6)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flutternativedraganddrop.