5,038 questions
0
votes
0
answers
7
views
How may I use one Kotlin Listview Adapter for 2 activities?
According to Android ListView Adapter multiple Activity and Can I use a single Custom Adapter for multiple activities in the same project?, it can be done. My code is as follows but it doesn't work. I ...
1
vote
1
answer
27
views
AdapterConfig.__init__() got an unexpected keyword argument 'mh_adapter'
I am trying adapters on LIMU-BERT, which is a lightweight BERT for IMU data. I pretrained LIMU-BERT on Dataset A and planned to add adapters and tune them on Dataset B. Here is my adapter-adding code:
...
0
votes
1
answer
30
views
Manage multiples views with a single listener
Any idea how to fix this horrible code so that a single touchlistener can handle all the clicks?
// Devices
val devices = DeviceDAO(context).getDevicesByType(2)
adapter = ...
0
votes
1
answer
153
views
Correct programming pattern to add methods and fields to canvas in javascript [closed]
I would like to create an html canvas class, managed with js, in order to drag & drop Path2Ds, zoom, and translate by drag & drop, so that everything is cleanly done on a class, not an ...
0
votes
1
answer
67
views
Need a good pattern for mapping entities between two data sources
I'm stuck with a very simple problem I can't find a simple solution to. I am looking for an elegant pattern to map data between two datasource
SourceA SourceB
ClassA1 -> ClassB1
ClassA2 -> ...
0
votes
0
answers
15
views
setAdapter(new adapter(insert())); and context connectting
I am on trying to saving checkbox value to be saved. and i typed the 'Context', it has problem with setAdapter on my mainactivity java. how can i solve this problem?
setAdapter insert () on my main ...
0
votes
0
answers
50
views
I have an issue with the screen not scrolling to the selected category when I choose a category
When I select a category, the screen scrolls down from the very top each time, like in the video I shared below. I want it to scroll from its current position to the selected category, and I still ...
0
votes
0
answers
20
views
AuthJS: Credential Provider not working with MongoDBAdapter
Here below is my auth.ts code for the latest next-auth.
The error message I am getting is here below
[auth][error] CredentialsSignin: Read more at https://errors.authjs.dev#credentialssignin
import ...
0
votes
0
answers
25
views
Print pdf file -> annotations not printed to the paper
if (cancellationSignal.isCanceled()) {
layoutResultCallback.onLayoutCancelled();
}
else {
PrintDocumentInfo.Builder builder=
new PrintDocumentInfo.Builder("Contract");
...
0
votes
2
answers
56
views
public void onBindViewHolder(MyViewHolder myViewHolder, int position)
Help me, i dont know why it is still get the error: Do not treat position as fixed; only use immediately and call myViewHolder.getAdapterPosition() to look it up later
Here is my code
public void ...
0
votes
0
answers
30
views
How to achieve Gemini Recycler View Effect that only shows the latest two components in RecyclerView?
I want my RecyclerView to display the latest message at the top of the visible screen, pushing the rest of the components up. Only the most recent component should be fully visible below it, similar ...
0
votes
0
answers
35
views
I am getting fragment not attached to context in onResume()
I have one fragment in which onResume() method, I am using requireContext(), but sometimes the application is getting crash when opening that fragment.
Here, is my current code for onResume()
...
0
votes
1
answer
58
views
How to start a camera intent and save picture taken to a specific location for each item in a listView
I'm new to programming and I don't know how to start camera intent from the adapter and to save image to a specific location for each item in the listview. I would like when I press the button ...
1
vote
0
answers
141
views
Windows 11 PowerShell shows my network adapter as False even though it's enabled
I am running Windows 11 Home with an Intel Killer Wi-Fi 6E AX1690i network adapter. Running PowerShell as an administrator, I have enabled the adapter, and in fact it is working properly. I have ...
0
votes
1
answer
33
views
How can I create an adapter that can adapt between two different data machine classes
A class that stores and handles access to some machine of type A:
class DataMachineA:
def __init__(self):
# some dummy data
self.data = {"type": ["A", "A&...