Close PDF with blocking UI - RadaeePDF.com
Signin/Signup with: 
Welcome, Guest
Username: Password: Remember me
Planned SDK features
  • Page:
  • 1

TOPIC:

Close PDF with blocking UI 1 week 6 days ago #15282

  • MaxM
  • MaxM's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 14
  • Thank you received: 0
Hi Radaee, there is such a question. When you exit the PDF of a large document (180 mb), the screen is locked, locked UI stream, a black screen appears and after 10 seconds, if you do not click, then everything closes successfully. Tell me what could be the problem or where to look for it? thanks

p.s. Clarification: This only happens when a new annotation has been added to the PDF (it feels like it is re-saving every page)

Please Log in or Create an account to join the conversation.

Last edit: by MaxM.

Close PDF with blocking UI 1 week 6 days ago #15283

  • radaee
  • radaee's Avatar
  • Offline
  • Moderator
  • Moderator
  • Posts: 1011
  • Karma: 43
  • Thank you received: 52
dear user:
are using demo?
or integrated on your project?

the demo code:
		if(m_doc != null)
		{
			m_view.PDFClose();
			m_doc.Close();
			m_doc = null;
		}
		if(m_doc != null)
		{
			m_view.PDFClose();
			m_doc.Close();
			m_doc = null;
		}
		if( m_asset_stream != null )
		{
			m_asset_stream.close();
			m_asset_stream = null;
		}
		if( m_http_stream != null )
		{
			m_http_stream.close();
			m_http_stream = null;
		}
		Global.RemoveTmp();
can be run on backing thread, if you do not want run on UI.

Please Log in or Create an account to join the conversation.

Last edit: by radaee.

Close PDF with blocking UI 1 week 5 days ago #15284

  • MaxM
  • MaxM's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 14
  • Thank you received: 0
Your library is integrated into our project.
The problem arises when an annotation is written or deleted on the pdf, probably it goes through / re-saves each page, tell me where is this happening? Thanks.

Please Log in or Create an account to join the conversation.

Close PDF with blocking UI 1 week 5 days ago #15285

  • radaee
  • radaee's Avatar
  • Offline
  • Moderator
  • Moderator
  • Posts: 1011
  • Karma: 43
  • Thank you received: 52
Document.Save() only update created and modified objects, this shall not be very long time.
only Document.SaveAs() or Document.ImportPage() to other Document will rewrite all objects.
you can use following java codes to print time span during exiting:
		long time1 = SystemClock.elapsedRealtime();
		//any exiting codes.
		int delta = (int)(SystemClock.elapsedRealtime() - time1);
		Log.e("Time", String.format("%d", delta));

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Powered by Kunena Forum