An Android Fragment that displays a dialog window, floating on top of its activity's window.
Questions tagged [dialogfragment]
472 questions
0
votes
0 answers
Android Caller Fragment's OnCreateView Not Called During Rotation with DialogFragment Displayed
So I have an Activity showing a Fragment (lets call A) which also shows a DialogFragment (lets call B). While "B" is open the user rotates and then dismisses "B". The result is "A" does not know any of it's variables anymore ... The main fragment…

Paul Hart
- 11
- 3
0
votes
1 answer
DialogFragment attaches to MainActivity instead of parent fragment activity
I create a DialogFragment from a Fragment and I have implemented a listener in the fragment, the problem is that the DialogFragment attaches to MainActivity instead of Parent Frame.
So I have this code in the DialogFragment which is called from the…

Mario
- 13,941
- 20
- 54
- 110
0
votes
1 answer
EditText.getText() returns the default/initial value when called in an inner class
I sought numerous answers/similar questions and non solved my problem. I have a custom dialog implemented in a class that extends "DialogFragment". When I try to get text from any of the layout components I get the initial default text that I…

AtlasS2626
- 3
- 3
0
votes
1 answer
Using PagerSlidingTabStrip on a DialogFragment
I am using this Library that I found on GitHub
PagerSlidingTabStrip
and its awesome. Been using it for sometime now. But recently, I tried to implement this on a DialogFragment and its not working properly. It crashes, and gives me this error…

ralphgabb
- 10,298
- 3
- 47
- 56
0
votes
1 answer
Android - Floating Alert Dialog which still enables user input in the main layout/activity
Good day, apologies for the confusing title.
I am creating an android application and I need a dialog/pop up to appear at a specific X Y Position. I already have a working DialogFragmet as shown below:
public class ItemDialog extends DialogFragment…

Razgriz
- 7,179
- 17
- 78
- 150
0
votes
1 answer
Error when calling dialog.show "Source not found" (Android)
I'm quite new to Android programming and now have my first problem I couldn't solve by searching.
I get a "Source not found" error when trying to show a custom alertdialog, that says "The source attachment does not contain the source for the file…

m8sch
- 13
- 3
0
votes
1 answer
Send data from one DialogFragment to another in Android
I have three fragments namely the AudioRecorderFragment which is a Fragment, UploadFragment which is a DialogFragment and another DialogFragment known as UploadPhotoDialog.
A user should record audio from the AudioRecorderFragment and then on…

mungaih pk
- 1,809
- 8
- 31
- 57
0
votes
1 answer
Android - Center text in DialogFrame
How can I center the dialog_more_information in the following Code?. Is it necessary to use a custom view?
Thanks in advance!.
This is how I call it >
@Override
public boolean onOptionsItemSelected(MenuItem item) {
switch (item.getItemId()) {
…

KillDash9
- 879
- 1
- 8
- 21
0
votes
1 answer
DialogFragment created from Fragment crashed after orientation changed
The problem is that DialogFragment has target not in fragment manager after orientation was changed; so overriding onDestroyView() and setting setRetainInstance(true) to Dialogfragment did not solve it!!
this code from MyFragment.java
public class…

Imla Assuom
- 189
- 10
0
votes
1 answer
android send data from Activity to DialogFragment
i am trying to make a app which set a alarm according to the timepicker, i have done this but i want the edittext from the mainactivity to be put into the alert dialog which is presented when the alrm goes off.
i want to send text from mainactivity…

user3694517
- 11
- 1
- 3
0
votes
1 answer
How to recreate a ListView in DialogFragment
I'm writing a DialogFragment for browsing the filesystem, which works really nice by now. I just got one Problem.
The files are shown in an ListView, and when the user selects a file, this event is send to the Activity that has called the Fragment…

Kevin Gebhardt
- 368
- 1
- 12
0
votes
3 answers
save value of a variable in a DialogFragment when the screen rotates
Well, I wanted to save value of a variable contained in a dialogFragment when the screen is rotated in Android. I've tried every method I could find on the internet, and none of them has worked for me. Some kill my application, and others simply…

MrCoquish
- 13
- 2
0
votes
0 answers
Android Don't calls onActivityResult with DialogFragment
I've got a code that starts intent to take picture from camera
Intent pictureActionIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);
startActivityForResult(pictureActionIntent, PhotoUtility.CAMERA_PICTURE);
And after picture is…

Denis Kotenko
- 83
- 8
0
votes
1 answer
How to dismiss a DialogFragment without going back to last item in stack
In trying to clean up code in an existing project and remove warnings about calling showDialog() in an Activity, I have moved a bunch of related dialogs which show up in a sequence into a new DialogFragment class. It's working OK, however when I…

Tim Rae
- 3,167
- 2
- 28
- 35
0
votes
1 answer
Android app - strange instantiation exception
An app crashed with the following msg:
android.support.v4.app.Fragment$InstantiationException: Unable to
instantiate fragment blabla.WelcomDialog: make sure class name exists,
is public, and has an empty constructor that is public
It crashed…

Marco Masci
- 818
- 10
- 22